Bug 408263 - Impossible create launch configurations from feature-based products using requires/imports
Summary: Impossible create launch configurations from feature-based products using req...
Status: NEW
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.2   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2013-05-16 11:58 EDT by Brian de Alwis CLA
Modified: 2023-03-29 02:09 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 Brian de Alwis CLA 2013-05-16 11:58:31 EDT
This is a follow-on to bug 365799.

We're encountering a problem using feature-based .product files for generating launch configurations where some of those features use requires/import to bring in bundle dependencies.  These .product files produce valid products when built with Tycho, but the launch configurations fail to launch in Eclipse.  This behaviour produces a confusing experience for developers who are not (and don't want to be) fully aware of the nuances of p2 and resolving dependencies.  Since development is increasingly moving to p2-based builds, it would be nice to have a solution that works with both modes.

The problem is due to a a mismatch in how PDE/Build and p2-based builders (Tycho) resolve dependencies: PDE/Build only includes the features and bundles specified, whereas Tycho attempts to resolve all dependencies in an opportunistic way.  PDE currently only supports the PDE/Build approach.

Currently the workaround is for developers to attempt to launch & fail, and then edit the launch configuration and select "add required bundles".  Unfortunately as "Add optional dependencies" is on by default, this often pulls in bundles that would not have otherwise been included; that is, it acts like the p2 greedy mode, which was disabled for Juno (bug 247099).

One possible workaround is to maintain a feature that includes these dependencies and include that in the .product file.  But this approach defeats the purpose of the looser coupling and reduces the flexibility of being able to do updates in the field.

I'd like to suggest that we somehow add an option to specify the dependency resolution mode.  I see two approaches:

1. Use a global preference (e.g., Preferences > Plug-in Development: Include dependencies when generating launch configurations).  I'd guess that it's unlikely that a developer would mix PDE/Build-based products in the same workspace as p2-based products.  This option could default to false for backwards compatibility, but seeing the trend away from PDE/Build, perhaps "true" would be the better default.

2. Add an option on the .product file.  In some respects this is a redundant flag, since the builders already have some kind of behaviour.
Comment 1 Curtis Windatt CLA 2013-05-30 17:31:08 EDT
Marking for 4.4 as this warrants some investigation.
Comment 2 Curtis Windatt CLA 2014-08-13 11:02:53 EDT
This is not an item PDE has time for.
Comment 3 Eclipse Genie CLA 2021-04-07 02:01:56 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 4 Eclipse Genie CLA 2023-03-29 02:09:44 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.