Debug JMeter response errors using a JSR223 listener
Understand why you see unusual JMeter errors when running your test in Flood
The best option would be to debug under load by using a JSR223 listener with the following Groovy code:
if (prev.isSuccessful() == false) {
log.info( "The Sample Label is : " + prev.getSampleLabel())
log.info( "The Start Time in milliseconds is : " + prev.getStartTime())
log.info( "The Response Code is : " + prev.getResponseCode() )
log.info( "The Response Message is : " + prev.getResponseMessage())
log.info( "Headers are: " + prev.getResponseHeaders())
}
When we recommended to use this option?
When the error rate is below 20%. We don't recommend you use this method if your error rate is 100%, as the problem should be obvious.
When the error is only happening under load. When the same problem happens locally with a single/few users, there is no need to use this method.
When monitoring live output logs for searching errors.
Last updated