Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 3.0.1
-
Fix Version/s: None
-
Component/s: Plugins and Lifecycle
-
Labels:None
-
Environment:maven 3.0.1, maven 3.0
-
Complexity:Intermediate
-
Number of attachments :
Description
In a multimodule (>120 modules) maven build, the compiler plug-in would seem to fail in creating a correct class-path every now and then.
Instead of this entry in maven -X logs for a single module build:
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile' with basic configurator -->
..
[DEBUG] (f) classpathElements = [/home/karniemi/"mymodulepath"/target/classes, /home/karniemi/.m2/repository/org/apache/servicemix/servicemix-utils/1.2.0/servicemix-utils-1.2.0.jar, /home/karniemi/.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, /home/karniemi/.m2/repository/org/codehaus/woodstox/wstx-asl/3.2.6/wstx-asl-3.2.6.jar, /home/karniemi/.m2/repository/org/apache/servicemix/specs/org.apache.servicemix.specs.jbi-api-1.0/1.4.0/org.apache.servicemix.specs.jbi-api-1.0-1.4.0.jar, /home/karniemi/.m2/repository/org/apache/geronimo/specs/geronimo-activation_1.1_spec/1.0.2/geronimo-activation_1.1_spec-1.0.2.jar, /home/karniemi/.m2/repository/log4j/log4j/1.2.14/log4j-1.2.14.jar]
every now and then I get this in the parallel build:
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile' with basic configurator -->
...
[DEBUG] (f) classpathElements = [/home/karniemi/"mymodulepath"/target/classes]
And of course the compilation fails because none of the dependencies are added to the classpath. Sometimes it goes fine in the multi-module build, but every now and then it fails for this.
In both maven runs I can see that the dependencies are resolved fine:
----------
[DEBUG] "mymodule":jar:DYNAMIC-SNAPSHOT
[DEBUG] junit:junit:jar:4.7:test
[DEBUG] org.apache.servicemix:servicemix-utils:jar:1.2.0:provided
[DEBUG] org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:jar:1.0.1:provided
[DEBUG] org.codehaus.woodstox:wstx-asl:jar:3.2.6:provided
[DEBUG] org.apache.servicemix.specs:org.apache.servicemix.specs.jbi-api-1.0:jar:1.4.0:provided (scope managed from compile) (version managed from 1.1.0)
[DEBUG] org.apache.geronimo.specs:geronimo-activation_1.1_spec:jar:1.0.2:provided
[DEBUG] log4j:log4j:jar:1.2.14:provided
-----------
The pluginArtifactMap looks like this:
--------------------
[DEBUG] (s) pluginArtifactMap =
--------------------
I'm really using jbi-maven-plugin for most of the modules, and that plugin binds the other plugins -also the compiler-plugin -to maven life-cycle phases.
Now that I've studied maven architecture a bit more, I suppose this is not a problem in the maven-compiler-plugin because the "classPathElements" is fed to it via the plug-in framework.
-I could not yet find out which maven/other component is setting up the wrong "classPathElements"
-Anyone have any idea, where to address this fault?