Gatling Frontline: Couldn't connect over HTTP to Local/localhost on port 9999: j.n.ConnectException: Connection refused

Hi All

When running my gatling frontline simulation I get the following error in my build logs:

The 2 lines that stand out to me the most are:
Couldn’t connect over HTTP to Local/localhost on port 9999: j.n.ConnectException: Connection refused.

Caused by: java.lang.IllegalArgumentException: Could not locate feeder file: Resource data.csv not found

`

[10:29:45,754] Cloning remote repository
[10:29:45,757] Cloning into ‘/tmp/frontline-5393204216914381621’…
[10:29:48,452] Start compiling project in ‘/tmp/frontline-5393204216914381621’
[10:29:48,452] Start deploying pool Local with 1 instance
[10:29:48,454] Pool Local deployed successfully: (Local/localhost).
[10:29:58,872] Compilation completed successfully.
[10:29:58,874] Collected jar (/tmp/frontline-5393204216914381621/target/maven-sample-1.0.0-shaded.jar)
[10:29:58,874] Packages successfully collected and instances successfully spawned. Proceeding with SSH checks.
[10:29:58,878] Connected over SSH to Local/localhost.
[10:29:58,878] All instances could be connected over SSH. Proceeding with Upload.
[10:29:59,684] Uploads to Local/localhost successful.
[10:29:59,684] All uploads successful. Proceeding with instance checking.
[10:29:59,749] Instance Local/localhost check successful.
[10:29:59,749] All instances check successful. Proceeding with starting injectors.
[10:29:59,752] Injector on instance Local/localhost successfully booted.
[10:29:59,752] All injectors successfully booted.
[10:30:00,773] Couldn’t connect over HTTP to Local/localhost on port 9999: j.n.ConnectException: Connection refused. 59 remaining tries.

[10:30:59,932] Couldn’t connect over HTTP to Local/localhost on port 9999: j.n.ConnectException: Connection refused. 1 remaining tries.
[10:30:59,934] Couldn’t connect over HTTP to Local/localhost on port 9999: j.n.ConnectException: Connection refused. Stopping.
[10:30:59,934] Injector on instance Local/localhost crashed. FrontLine will now try to check if the injector process is still running and kill it.
[10:30:59,952] Injector process crashed on instance Local/localhost. Proceeding with fetching JVM crash log.
[10:30:59,955] Failed to retrieve JVM crash log: head: cannot open ‘/tmp/frontline-c9bd592b-6a79-4120-84c3-1eb45b48c389/hs_err_pid8868.log’ for reading: No such file or directory
[10:30:59,958] Injector log successfully retrieved: Exception in thread “main” java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at io.gatling.app.Runner.run0(Runner.scala:74)
at io.gatling.app.Runner.run(Runner.scala:60)
at io.gatling.app.Gatling$.start(Gatling.scala:73)
at io.gatling.app.Gatling$.fromArgs(Gatling.scala:46)
at io.gatling.app.Gatling$.main(Gatling.scala:38)
at io.gatling.app.Gatling.main(Gatling.scala)
Caused by: java.lang.IllegalArgumentException: Could not locate feeder file: Resource data.csv not found
at io.gatling.core.feeder.FeederSupport.separatedValues(FeederSupport.scala:41)
at io.gatling.core.feeder.FeederSupport.separatedValues$(FeederSupport.scala:38)
at io.gatling.core.Predef$.separatedValues(Predef.scala:24)
at io.gatling.core.feeder.FeederSupport.csv(FeederSupport.scala:32)
at io.gatling.core.feeder.FeederSupport.csv$(FeederSupport.scala:31)
at io.gatling.core.Predef$.csv(Predef.scala:24)
at PortalLoadTest.(PortalLoadTest.scala:10)
… 10 more
.scala:38)
at io.gatling.app.Gatling.main(Gatling.scala)
[10:30:59,979] Instances List() could not be reached so FrontLine could not make sure Gatling process is down.
[10:30:59,980] Gatling processes on instances List() were all down.
[10:30:59,980] Stopping.
[10:30:59,980] Local: instances successfully stopped
[10:30:59,991] Cleaning build directory /tmp/frontline-5393204216914381621
[10:30:59,992] Successfully deleted uploaded resources on injector Local/localhost

`

FrontLine Version: 1.7.1

Gatling Version: 3.1.2.FL

Simulation Build Configuration
Maven Project

Using a private GitHub repo so I cannot share but I can give you an overview of the structure:
Top level
-pom.xml (copied from the gatling frontline sample simulations)
-data/data.csv

-src/test/scala/frontline/PortalLoadTest.scala

Pool configuration
Local 1

This PortalLoadTest.scala runs fine from the local version of gatling but now I need to get it running from the frontline AWS setup.
Although it should be noted the csv file is stored slightly differently locally.
Top level

  • user-files/simulations/PortalLoadTest.scala
  • user-files/data.csv

This is the only directory structure I could get my csv file to load in successfully locally even though https://gatling.io/docs/2.3/session/feeder says I should have it in a data directory :shrug.

This is some what of an urgent query as we have a load testing deadline to hit so any help would be much appreciated.

Thank you.

Hello Joe,

The layout was changed in Gatling 3, see https://gatling.io/docs/current/migration_guides/2.3-to-3.0/

  • bodies and data directories were dropped, now those files are resolved from classpath root, see #3398.

Actually, your error is pretty explicit:

Could not locate feeder file: Resource data.csv not found

-data/data.csv

If your feeder file is placed in the data package, you have to configure the correct location, eg csv(“data/data.csv”), not csv(“data.csv”).

BTW, the correct address for FrontLine support is support@gatling.io.

Regards,

Hi Stéphane

Thank you for this. Just to clarify for anyone reading this post I put my data.csv in:
src/test/resources
and it worked.

This information was not very clear in your documentation yes it was in your migration guide but I would have to of known to look there.

Joe