Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 142328

Summary: [j2ee] Build path contains duplicate entries
Product: [WebTools] WTP Java EE Tools Reporter: Igor Fedorenko <igor>
Component: jst.j2eeAssignee: Jason Sholl <jsholl>
Status: CLOSED DUPLICATE QA Contact: Chuck Bridgham <cbridgha>
Severity: major    
Priority: P2 CC: dvoytenko, konstantin
Version: 1.5   
Target Milestone: 1.5 RC5   
Hardware: PC   
OS: Windows XP   
Whiteboard: PMC_approved
Attachments:
Description Flags
patch for FlexibleProjectContainer none

Description Igor Fedorenko CLA 2006-05-17 15:54:32 EDT
Our (rather large) team uses both WTP 1.0 and WTP 1.5 to work on the code that is shared through CVS. Recent changes to "Web App Libraries"  classpath container broke compatibility between the two WTP versions and projects created in WTP 1.0 do not compile in WTP 1.5 any more. More specifically,

In WTP 1.0 dependent projects were *not* included into "Web App Libraries" classpath container, instead they were added as java project dependencies to .classpath.

In WTP 1.5 "Web App Libraries" classpath container now includes dependent projects too, which results in duplicated entries if WTP 1.5 is used on a project created in WTP 1.5.

I see two related issues. 

First, as discussed on dev least few weeks ago, it is important to support such mixture of WTP versions as it is unrealistic to expect large teams to move from one version to another without transition period during wich the two versions will have to coexist.

Second, when the time is right, WTP 1.5 should know how to properly migrate projects from the old version.

PS: I do beleive that dependent projects should be added to "Web App Libraries" classpath container, not as separate java project dependencies.
Comment 1 John Lanuti CLA 2006-05-17 16:23:08 EDT
Chuck, is this related to the work you and Jason were doing?
Comment 2 Chuck Bridgham CLA 2006-05-18 14:42:29 EDT
Hi Jason,

We really need to look at this as we have stated backward compatibility with 1.0 workspaces.....

I know this is painful, but we may need to go to a model of the containers only contributing the dependent component classpath if it already doesn't exist.
Comment 3 Neeraj Agrawal CLA 2006-05-25 12:55:25 EDT
*** Bug 139241 has been marked as a duplicate of this bug. ***
Comment 4 Neeraj Agrawal CLA 2006-05-25 12:57:30 EDT
As pointed out in defect  https://bugs.eclipse.org/bugs/show_bug.cgi?id=139241, while checking for existing entries it should also be checked if the particular entry exists in  any one of the existing containers.
Comment 5 Eugene Kuleshov CLA 2006-05-25 13:09:33 EDT
It looks like Igor describing two separate issues here:

-- Compatibility between WTP 1.0 and 1.5 (somebody would have to look at the migration path)

-- Duplicated entries in a build path, which was previously reported in Bug 139241 (from a slightlly different angle though)
Comment 6 Jason Sholl CLA 2006-06-05 13:05:16 EDT
This patch is also included in the latest patch for bug 144023 as these two bugs slightly overlap.
Comment 7 Jason Sholl CLA 2006-06-05 13:07:11 EDT
Created attachment 43496 [details]
patch for FlexibleProjectContainer
Comment 8 Jason Sholl CLA 2006-06-05 17:55:17 EDT
duplicating against 144023 because the patch for that bug also contains this patch.

*** This bug has been marked as a duplicate of 144023 ***
Comment 9 Tim Wagner CLA 2006-06-06 15:14:56 EDT
+1 1.5
Comment 10 Igor Fedorenko CLA 2006-06-26 23:02:24 EDT
What about migration part of the original report? Few words in "New and Noteworthy" should be enough.
Comment 11 Eugene Kuleshov CLA 2006-08-30 17:19:47 EDT
Somehow related bug 154251
Comment 12 Jason Sholl CLA 2006-09-25 15:07:22 EDT
closing.