Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 311993 - Adding the "Pull in classpath elements..." reference to a web project causes the project not to build
Summary: Adding the "Pull in classpath elements..." reference to a web project causes ...
Status: RESOLVED DUPLICATE of bug 311981
Alias: None
Product: WTP Java EE Tools
Classification: WebTools
Component: jst.j2ee (show other bugs)
Version: 3.2   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 3.2 RC1   Edit
Assignee: Jason Sholl CLA
QA Contact: Chuck Bridgham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-06 20:58 EDT by Larry Isaacs CLA
Modified: 2010-05-10 09:58 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Larry Isaacs CLA 2010-05-06 20:58:59 EDT
If you create a dynamic web project and a utility project, then add an external jar to the Java build path of the utility project, you can use the Deployment Assembly page to mark the external jar for "publish/export" by clicking Add and using the "Referenced Projects Classpath Entries" in the New Reference Wizard.  After marking the external jar with a check and clicking Finish, the "Pull in classpath elements from referenced projects" reference gets added to the dynamic web project.  This reference causes a build path cycle which prevents the project from building.

The problem is that J2EEComponentClasspathContainer.update() is adding the referenced component from the "Pull in classpath elements..." reference to the web project's classpath, which is the web project itself, creating the cycle.  I'm not sure what mechanism is appropriate so J2EEComponentClasspathContainer will ignore this "special" reference.
Comment 1 Larry Isaacs CLA 2010-05-06 21:53:24 EDT
It appears this bug may be a duplicate of Bug 311981.  The "Pull in classpath elements..." reference has a dependency type of "consumes" so the changes to J2EEComponentClasspathContainer found in the patch for Bug 311981 fixes this bug as well.  Since this use case might have additional issues to consider, I'll leave it to others to officially declare it to be a duplicate.
Comment 2 Carl Anderson CLA 2010-05-10 09:18:01 EDT
Assigning to Jason Sholl for initial investigation (and duplication, if appropriate.)
Comment 3 Jason Sholl CLA 2010-05-10 09:58:43 EDT
Yes, this is a duplicate of bug 311981.

*** This bug has been marked as a duplicate of bug 311981 ***