Rishi
Rishi

Reputation: 115

Uncaught Exception ERROR - When running a JMeter Via JENKINS

I am trying to run a very simple test in Jenkins using JMeter.

JMeter Version 2.13 & Running Jenkins Locally and JMeter is also stored locally.

Executing in Jenkins using windows batch command.

when running the job in Jenkins i get the following error message in Console Output:

Uncaught Exception java.lang.ExceptionInInitializerError. See log file for details. Uncaught Exception java.lang.NoClassDefFoundError: Could not initialise class org.apache.jmeter.gui.util.MenuFactory. See log file for details.

I went to manage Jenkins and system logs but no information in there.

Any ideas?

Upvotes: 1

Views: 1615

Answers (1)

Karthikeya
Karthikeya

Reputation: 314

As it is java related exception, please check your jdk settings in jenkins by follwing below steps

  1. Manage Jenkins -> Global Tool Configuration. You can find JDK tab.
  2. Under JDK give the path of jdk folder for Java_Home variable

Please take free style project in jenkins and configure as in below images

In the place of directory under custom work space give the path of bin folder of jmeter

enter image description here

In the place of Test.jmx give your jmx file name

enter image description here

When you build the project you can see the console output as below image

enter image description here

Upvotes: 1

Related Questions