JMeter: How to find out the cause of java.net.SocketTimeoutException?

I do a load test for my web application, and I set the connection timeout and response time to 20 seconds, and sometimes I get exceptions, for example:

Non HTTP response code: java.net.SocketTimeoutException: Non HTTP response message: Read timed out

I get the above exception as a result of the JMeter test, and there are no errors in my application, and there is no stacktrace to track the exception.

I want to know what the reason for the message is: is the application waiting for something to process either slow SQL or a stream or an application that has refused connections because maxed out?

please advise how I can find out the reason for this exception and how to fix it.

+4
source share
2 answers

I would recommend that you improve your debugging work (in jMeter) as follows:

  • try adding a debug post processor to your http sampler

debugPostProcessor

  • launch log viewer (jMeter log viewer before any http sampler execution (-s) / script (- s)

log viewer

This will probably help you understand why you encountered a socket timeout. Hope this helps you.

0
source

If you want to know what causes the error, look at the lines that cause the error and see what they do. Then try to think what might go wrong when they do their job. If you need further help, please submit the code that causes the error, as a SocketTimeoutException may be caused by several things.

-2

Source: https://habr.com/ru/post/1547337/


All Articles