I ran the recorder with Package set to nothing and Class Name set to AAA.
It produced a recorder simulation in ./user-files/simulations/AAA.scala
To run this simulation I did:
./bin/gatling -s AAA
It seemed to run the right simulation as expected.
Then I copied AAA.scala to AAA2.scala (in the user-files/simulation directory) and edited it to add more users. I even changed the class in the scala code from AAA to AAA2
I’m trying to produce 2 separate simulations, in 2 separate files, one which creates a load of about 10% and the other of 80%.
When I run with -s to specify the file I want to use it doesn’t seem to do what I expect. It always seems to use the more recent one?
For example, this command now runs the new AAA2.scala???
./bin/gatling -s AAA
Can someone explain what -s really does. I assumed it used the -s to look for a filename in user-files/simulations with that name but it doesn’t seem to do that? When you use words like “Class Name” please explain where in the code or the filename that comes from?
Thanks. Can I use -s without a package name? I’m assuming that -s was not the right answer since it didn’t work.
Do I add the dot? -s .AAA
I switched to not using the package name because my goal is to:
start the simulation with gatling.sh -s AAA -nr
kill it after a while
run gatling.sh with -ro
I could not figure out the format for the argument to -ro when I used a package name. Would it be “p.AAA” ? I couldn’t get it to work so I stopped using a package name.
It is possible that I messed up the class names and the files but I don’t think so. I will go check again right now!
I have a question about case sensitivity. When my class name was Aaaa and I passed the -ro option to gatling.sh, I had to lowercase the Aaaa to aaaa to get it to work. I mean I passed -ro aaaa and it worked but -ro Aaaa said it could not find a matching results. Does that make any sense at all to you? I’m running on Unix.
I solved the problem I was having. The key was that you told me that the class name comes from the .scala file. Therefore, it reads all the .scala files in the user-files/simulations directory to find the one I asked for. I had a bad .scala file that I was working on that had a syntax error in it. So it looked like it was always choosing the one with the syntax error regardless of what I asked for.
I removed the bad one and it started working as I expected again.