maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Scholte" <>
Subject Re: Classloading issues in maven plugin with custom lifecycle mapping
Date Tue, 12 Apr 2016 18:09:25 GMT

do you have an example project (e.g. at github) to reproduce it?
Not sure if this is the issue, but maven-plugins cannot be part and used  
by a multimodule project. Before a project can be built, all plugins must  
be resolved. This shouldn't be an issue, since a maven-plugin should have  
a different lifecycle compared to a multimodule-project using it.


On Tue, 12 Apr 2016 15:16:01 +0200, Christofer Dutz  
<> wrote:

> Hi,
> I am currently working on converting Apache Flex from Ant to Maven. I  
> have managed to convert all of the Ant stuff in our newest SDK. I even  
> built a new maven plugin for doing the Flex compilation. All parts seem  
> to be working great.
> The build consists of:
> - A compiler
> - Some Framework libs that are build using the compiler
> The maven plugin is not part of the build. The maven plugin has a  
> plugin-dependency to the compiler artifact. It is used in the framework  
> modules to build the flex artifacts.
> Now if I just build the compiler or I just build the framework, all  
> works fine. But if I build compiler and framework in the same build, the  
> flex maven plugin complains about not being able to find the classes of  
> the compiler. The dump of the classpath lists the compiler.jar, but it  
> doesn't seem to be able to load any classes from it. If I take the  
> context classloader inside the plugin and create a new instance with the  
> exact same URLs, I am able to manually load the class.
> I assume that this is due to the fact that the compiler jar is replaced  
> during the build after getting a handle to the jar file and before using  
> it. But that is just a well educated guess. Is there anything I could do  
> to make this build work?
> I am also having builds randomly fail because artifacts that are used b  
> plugins are replaced during the build, but I couldn't quite pin the  
> problem down to a cause.
> Probably when I asked this question on the user list, this was too  
> specific for that list, as I didn't get a single response. Hopefully on  
> this list it will be different :-)
> I would really appreciate a little Help here ... It's definitely worth  
> at least a beer in Vancouver ;-)
> Chris

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message