oliverlloyd / jmeter-ec2

Automates running Apache JMeter on Amazon EC2
GNU General Public License v3.0
464 stars 187 forks source link

CTRL-C trap to stop test does not work when jmeter encounters http errors #77

Closed light-handle closed 7 years ago

light-handle commented 8 years ago

CTRL-C trap to stop test does not work when jmeter encounters http errors (Eg: SocketException). Running this from inside docker container.

oliverlloyd commented 7 years ago

I'm not sure this is entirely related to the script, JMeter can just be a pain to stop sometimes.

So when you hit CTRL-C the script sends a call to /bin/stoptest.sh on each slave. This is asking JMeter to stop nicely and waiting for it to do so. Trouble is, JMeter will often ignore you while it waits for a socket connection attempt to timeout so this is why the script appears to not work, it's simply waiting for JMeter.

You could possibly have a timeout set here, you could even write a countdown to the screen like: Waiting for JMeter to stop...12 seconds remaining... and then tick that down until you give up and terminate the instances.

In any case, arguably, this is a JMeter bug so I'm closing this one for now but if I've read this wrong feel free to reopen.