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

Bug 323286

Summary: Product Build can select plugin that was not published
Product: [Eclipse Project] PDE Reporter: Andrew Niefer <aniefer>
Component: BuildAssignee: pde-build-inbox <pde-build-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: bhunt, darin.eclipse
Version: 4.0   
Target Milestone: 3.7 M2   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
patch none

Description Andrew Niefer CLA 2010-08-20 14:57:28 EDT
Given a state that contains multiple versions of some bundle, and a product that includes that bundle, it is possible for PDE/Build to generate metadata for one version of the bundle, but for the product to be created requiring the other one.

The immediate cause of this is when replacing versions in the .product file, build is just getting the bundles from the state and selects the resolved bundle with the highest version.

When generating metadata, we are doing it for the bundle that was actually selected by the features.

There seems to be cases where these are not the same bundle.  This leads to problems later when trying to install the product because we don't have metadata for the correct version.


Also need to investigate why these aren't the same bundle.  PDE/UI is generating the feature.xml and selecting the bundle version using State#getBundle(name,version).  Javadoc for this says the highest version is returned if there are multiple resolved bundles.
PDE/Build uses State#getBundles(name) and does the sort itself.
Comment 1 Andrew Niefer CLA 2010-08-25 11:57:04 EDT
Created attachment 177434 [details]
patch
Comment 2 Andrew Niefer CLA 2010-08-25 11:57:22 EDT
patch released to head