gatlingscala-gatlinggatling-plugin

Gatling scala gradle, HowTo set requestTimeout


I'm using gatling gradle plugin and I'm trying to increase default timeout.

This doesn't work. I constantly get

> i.g.h.c.i.RequestTimeoutException: Request timeout to localhos     47 (94,00%)
t/127.0.0.1:8080 after 60000 ms

my gatling.conf is

gatling {
  core {

  http {
    pooledConnectionIdleTimeout = 600000       # Timeout in millis for a connection to stay idle in the pool
    requestTimeout = 1000000                    # Timeout in millis for performing an HTTP request
  }

  }
}

I tried to corrupt my gatling.conf and build ruins

/build/resources/gatling/gatling.conf: 8: Key 'qd  qw  qd  qd' may not be followed by token: 'core' (if you intended 'core' to be part of a key or string value, try enclosing the key or value in double quotes)

So gatling really tries to read my file but doesn't want to override setting.

Who knows how to override it?


Solution

  • Your configuration file is wrong.

    Your file, properly formatted:

    gatling {
      core {
        http {
          requestTimeout = 1000000
        }
      }
    }
    

    How it should be, like in the documentation:

    gatling {
      core {
        # core options
      }
      http {
        requestTimeout = 1000000
      }
    }