Hello!

I have a problem getting jmeter to start a javaclass when I have the Java 
Request inside an If-Controller.

The testplan consists of several Thread Groups, each responsible for starting a 
java class with the help of a Java Request.
This testplan has been run several times with no similar problems.

I have now modified it a bit so that each Thread group has it's own variable 
with an If-Controller to see if it should run the Java Request or not.

The first errors I got was:
Uncaught Exception java.lang.ExceptionInInitializerError in thread 
Thread[#36,Kuverthandlaggning 3-1,5,main]. See log file for details.
Uncaught Exception java.lang.NoClassDefFoundError: Could not initialize class 
org.codehaus.groovy.runtime.InvokerHelper in thread 
Thread[#37,Kuverthandlaggning 3-2,5,main]. See log file for details.

I then tried tried to delete the If-Controller and the Java Request as they 
were copied, (we have encountered problems with copied stuff before) remade new 
ones, I then instead got the error message:
Uncaught Exception java.lang.StackOverflowError in thread 
Thread[#36,Kuverthandlaggning 3-1,5,main]. See log file for details.

I then tried to change to number of threads to 1 and to only do 1 loop count in 
the Thread Group I was testing with.
With this change, I no longer get any error messages in the console but the 
test never starts. I test it by debuging in Intellij.

However, if I move the Java Request out of the If-Controller, and have it 
directly under the Thread group like we used to have before the changes, 
everything works fine.
How come when I add an If-Controller to the equation everything breaks down?

This doesn't work:
[cid:image001.png@01DB1573.0FC59170]

This works:
[cid:image002.png@01DB1574.3CF52510]

I have double checked with logging that I actually get inside the If-Controller 
when the expression is true, so I can confirm that that is not the problem.

Have anyone else had any experience of this or do you have any clues on why 
it's not working?

Kind regards Nick


Vill du veta hur Pensionsmyndigheten hanterar dina personuppgifter? Se 
myndighetens webbplats.
https://www.pensionsmyndigheten.se/om-pensionsmyndigheten/allmanna-handlingar/om-personuppgifter

Reply via email to