Bug 430319 - Incorrect builders when aspectj-maven-plugin is in pluginManagement
Summary: Incorrect builders when aspectj-maven-plugin is in pluginManagement
Status: NEW
Alias: None
Product: AJDT
Classification: Tools
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 major with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: AJDT-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-13 16:28 EDT by Christopher Smith CLA
Modified: 2014-03-13 17:57 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christopher Smith CLA 2014-03-13 16:28:24 EDT
When m2e imports a Maven module whose parent declares a pluginManagement entry for aspectj-maven-plugin but which does not list any build plugins itself, m2e erroneously adds the ajbuilder and ajnature to the project and silently fails to actually compile the Java classes in the module. This leads to inexplicable "class not found" errors in projects depending on that module. The issue is resolved by issuing an "mvn compile" command at the CLI until the next time Eclipse deletes the class file.

I've had some trouble reproducing this error, so it's possible there's another interaction going on, but I've seen behavior like this going back to (I think) the version 1.0 bump when non-AJ modules in a project depend on AJ modules.

Steps to reproduce:

- Specify a configuration for the aspectj-maven-plugin in the parent POM P.
- Create module A with a plugin stanza for aspectj-maven-plugin.
- Create module B without the stanza, just using regular maven-compiler-plugin.
- Import project P to Eclipse. Inspect B/.project and note the ajnature.
- Add classes to B. These classes will not be compiled into target/classes (or anywhere else).
Comment 1 Fred Bricon CLA 2014-03-13 17:57:09 EDT
m2eclipse-ajdt is not maintained by the m2e team. Moving over to the AJDT project.