JENKINS Maven Build Failure

299 views Asked by At

When i try to build my project using Jenkis i got the following error:

Caused by: org.apache.maven.plugin.PluginContainerException: An API incompatibility was encountered while executing org.wso2.maven:wso2-esb-proxy-plugin:2.0.12:pom-gen: java.lang.ExceptionInInitializerError: null

realm =    plugin>org.wso2.maven:wso2-esb-proxy-plugin:2.0.12
strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
urls[0] = file:/home/jira/.m2/repository/org/wso2/maven/wso2-esb-proxy-plugin/2.0.12/wso2-esb-proxy-plugin-2.0.12.jar
urls[1] = file:/home/jira/.m2/repository/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.jar
urls[2] = file:/home/jira/.m2/repository/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar
urls[3] = file:/home/jira/.m2/repository/org/apache/maven/shared/maven-dependency-tree/1.2/maven-dependency-tree-1.2.jar
urls[4] = file:/home/jira/.m2/repository/junit/junit/3.8.1/junit-3.8.1.jar
urls[5] = file:/home/jira/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar
urls[6] = file:/home/jira/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.7/plexus-utils-1.4.7.jar
urls[7] = file:/home/jira/.m2/repository/org/wso2/maven/org.wso2.maven.capp/2.0.12/org.wso2.maven.capp-2.0.12.jar
urls[8] = file:/home/jira/.m2/repository/org/apache/ws/commons/axiom/wso2/axiom/1.2.9-wso2v1/axiom-1.2.9-wso2v1.jar
urls[9] = file:/home/jira/.m2/repository/javax/mail/mail/1.4/mail-1.4.jar
urls[10] = file:/home/jira/.m2/repository/javax/activation/activation/1.1/activation-1.1.jar
urls[11] = file:/home/jira/.m2/repository/org/apache/ws/commons/axiom/axiom-impl/1.2.9-wso2v1/axiom-impl-1.2.9-wso2v1.jar
urls[12] = file:/home/jira/.m2/repository/org/apache/ws/commons/axiom/axiom-api/1.2.9-wso2v1/axiom-api-1.2.9-wso2v1.jar
urls[13] = file:/home/jira/.m2/repository/jaxen/jaxen/1.1.1/jaxen-1.1.1.jar
urls[14] = file:/home/jira/.m2/repository/xerces/xercesImpl/2.6.2/xercesImpl-2.6.2.jar
urls[15] = file:/home/jira/.m2/repository/org/apache/geronimo/specs/geronimo-activation_1.1_spec/1.0.2/geronimo-activation_1.1_spec-1.0.2.jar
urls[16] = file:/home/jira/.m2/repository/org/apache/geronimo/specs/geronimo-javamail_1.4_spec/1.6/geronimo-javamail_1.4_spec-1.6.jar
urls[17] = file:/home/jira/.m2/repository/org/codehaus/woodstox/wstx-asl/3.2.9/wstx-asl-3.2.9.jar
urls[18] = file:/home/jira/.m2/repository/org/apache/geronimo/specs/geronimo-stax-api_1.0_spec/1.0.1/geronimo-stax-api_1.0_spec-1.0.1.jar
urls[19] = file:/home/jira/.m2/repository/org/apache/ws/commons/axiom/axiom-dom/1.2.9-wso2v1/axiom-dom-1.2.9-wso2v1.jar
urls[20] = file:/home/jira/.m2/repository/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar
urls[21] = file:/home/jira/.m2/repository/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar
urls[22] = file:/home/jira/.m2/repository/org/wso2/maven/org.wso2.maven.utils/2.0.2/org.wso2.maven.utils-2.0.2.jar
urls[23] = file:/home/jira/.m2/repository/org/wso2/maven/org.wso2.maven.core/2.0.3/org.wso2.maven.core-2.0.3.jar
urls[24] = file:/home/jira/.m2/repository/org/wso2/maven/org.wso2.maven.esb/2.0.3/org.wso2.maven.esb-2.0.3.jar
Number of foreign imports: 1
import: Entry[import  from realm ClassRealm[project>it.innovapuglia.diogene.integration.diogene-wso2:Diogene-WSO2Artifacts:1.0c-rc2.0-SNAPSHOT, parent: ClassRealm[maven.api, parent: null]]]

at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:179)
... 31 more
Caused by: java.lang.ExceptionInInitializerError
at org.apache.axiom.om.OMAbstractFactory.getMetaFactory(OMAbstractFactory.java:68)
at org.apache.axiom.om.OMAbstractFactory.getOMFactory(OMAbstractFactory.java:107)
at org.wso2.maven.core.model.AbstractXMLDoc.<clinit>(AbstractXMLDoc.java:47)
at org.wso2.maven.esb.utils.ESBMavenUtils.retrieveArtifacts(ESBMavenUtils.java:42)
at org.wso2.maven.esb.utils.ESBMavenUtils.retrieveArtifacts(ESBMavenUtils.java:36)
at org.wso2.maven.proxy.ProxyServicePOMGenMojo.retrieveArtifacts(ProxyServicePOMGenMojo.java:102)
at org.wso2.maven.proxy.ProxyServicePOMGenMojo.execute(ProxyServicePOMGenMojo.java:107)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
... 31 more
Caused by: org.apache.commons.logging.LogConfigurationException: User-specified log class 'org.apache.commons.logging.impl.Log4JLogger' cannot be found or is not useable.
at org.apache.commons.logging.impl.LogFactoryImpl.discoverLogImplementation(LogFactoryImpl.java:874)
at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:604)
at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:336)
at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:310)
at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:685)
at org.apache.axiom.injection.FactoryInjectionComponent.<clinit>(FactoryInjectionComponent.java:34)
... 39 more

Instead, when i try to build it locally using my installed maven... the build ends successfully without any problem.

The maven jenkins command i launch is a simple

mvn clean install -P MyProfile...

I cannot figure out why there is an exception related to log4j commons... What could be the problem?

0

There are 0 answers