Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 334034 - [target] IU containers do not report all contained features
Summary: [target] IU containers do not report all contained features
Status: VERIFIED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.7   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 major (vote)
Target Milestone: 3.7 M5   Edit
Assignee: Curtis Windatt CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
: 337187 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-01-11 16:06 EST by Jeff McAffer CLA
Modified: 2011-02-17 04:23 EST (History)
2 users (show)

See Also:


Attachments
patch to add the features (4.40 KB, patch)
2011-01-11 16:06 EST, Jeff McAffer CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jeff McAffer CLA 2011-01-11 16:06:05 EST
Created attachment 186566 [details]
patch to add the features

in i0104

if you have a target with IUBundleContainers (software sites), the features included by the features added from the site do not show up in the PDE model.  As a result, they are not available for addition to products and other features.

After some discussion with Curtis, we decided to have IUBunldeContainer.getFeatures return all features in the underlying profile.  This means that multipe IU containers will return duplicate features.  TargetDefinition.getAllFeatures was updated to remove duplicates (likely a good change anyway) to compensate.  The alternative to this would be to run the slicer for each container and slice the profile with the container's roots.  This is certainly doable but is likely reasonably expensive.

I'm attaching a patch that addresses the problem.

Would be great to get this in for M5 as the problem is somewhat major for folks using features.
Comment 1 Curtis Windatt CLA 2011-01-21 16:36:24 EST
Fixed in HEAD.  Only change was to add back the return if no feature IUs were found.  Was there a specific reason this was eliminated?  The result should be the same, but exiting early saves looking through all known feature models and creating NameVersionDescriptor objects for all of them.

Thanks for the contribution.
Comment 2 Jeff McAffer CLA 2011-01-22 17:20:56 EST
I don't recall removing the return on purpose.  Thanks for catching that.  usually I try to change as little as possible.
Comment 3 Curtis Windatt CLA 2011-01-26 12:50:12 EST
Verified in I20110126-0800
Comment 4 Gunnar Wagenknecht CLA 2011-02-17 04:23:34 EST
*** Bug 337187 has been marked as a duplicate of this bug. ***