Unable to close Websocket in JMeter

71 Views Asked by At

We are simulating websocket request in jmeter and using Websocket Close Sampler to close the Websocket post Write and Read.

However , we are getting error Connection Reset for Websocket Close Sampler.

Pls let us know if we are missing something in this.

Thanks in advance.

We tried with the Runtime controller and default samplers but still unable to close the connection and connections are still alive if we are checking at server side.

1

There are 1 best solutions below

1
Dmitri T On

It's hard to say anything without seeing your Test Plan and jmeter.log file (preferably with JMeter debug logging enabled for WebSocket protocol support)

You can enable it by adding the next line to log4j2.xml file (lives in "bin" folder of your JMeter installation:

<Logger name="eu.luminis" level="debug" />

If you're using open connection sampler it should be possible to close the connection with close connection sampler. It worth checking whether your system under test properly handles connection termination from the client side as well.