(This article is part of the JMeter Series)

Useful ways to debug JMeter as far as I know:

  • insert a “Debug Sampler”

Debug Sampler Screenshot

the “Debug Sampler” will emit “everything that’s known” to JMeter. That output can be displayed in the “View Results Tree Listener”:

Debug Sampler Result Screenshot

  • have a look at the JMeter log file (which is usually dumped from where you’ve started JMeter)

  • check the output of one of the listeners such as the “View Results Tree Listener”.

  • if you need to debug regexes of a “Regular Expression Extractor” then you can have a look at the source code of the page you want to extract a value from inside the “View Results Tree Llistener” and enter the same regular expression in the “Search” field (searching is only implemented in JMeter > v2.4).

Debugging Regexes Screenshot

In that picture you can see JMeter matching and displaying the regex entered in the search field inside an HTML page retrieved though the “HTTP Client Sampler”.

Tomáš Pospíšek, 1.1.2011