-
Bug
-
Resolution: Unresolved
-
Major
-
Jenkins installed in Linux server.
Hi Team, Recently, We have been upgraded the Jenkins from 1.466 to 1.509.2 version. Also we have been updated all the available plugins including Maven plugin.
All the Maven jobs after upgradation of Jenkins gets failed with the below error log(full log)
Started by timer
[EnvInject] - Loading node environment variables.
Building remotely on <slavename> in workspace /home/hudson/slave3/workspace/event-driven-app
FATAL: Null value not allowed as an environment variable: M2_HOME
java.lang.IllegalArgumentException: Null value not allowed as an environment variable: M2_HOME
at hudson.EnvVars.put(EnvVars.java:172)
at hudson.tasks.Maven$MavenInstallation.buildEnvVars(Maven.java:474)
at hudson.maven.MavenModuleSetBuild.getEnvironment(MavenModuleSetBuild.java:172)
at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:783)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1367)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:674)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:579)
at hudson.model.Run.execute(Run.java:1575)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:477)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:237)
But after changing the version of Maven to any of the other version by saving it and resaved the correct maven version(2.2.1) configuration in the job the error is getting resolved and build gets succeeded.
Kindly advise on the error/fix for the same