Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 510926 - RCP 3.x Templates (HelloRCP, OneView, Intro, RCP Mail) no more working since Neon
Summary: RCP 3.x Templates (HelloRCP, OneView, Intro, RCP Mail) no more working since ...
Status: VERIFIED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.6   Edit
Hardware: PC Windows NT
: P3 normal (vote)
Target Milestone: 4.7 M7   Edit
Assignee: Vincenzo Caselli CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 509436
Blocks:
  Show dependency tree
 
Reported: 2017-01-24 05:02 EST by Vincenzo Caselli CLA
Modified: 2017-05-18 04:53 EDT (History)
3 users (show)

See Also:


Attachments
Proposed patch (5.62 KB, patch)
2017-01-24 05:17 EST, Vincenzo Caselli CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vincenzo Caselli CLA 2017-01-24 05:02:12 EST
Since Neon, when creating a new Plug-in Project using one of the following Templates:
- RCP 3.x application (minimal) - aka 'Hello RCP'
- RCP 3.x application with a view
- RCP 3.x application with an intro
- RCP 3.x Mail Template

the launch of the generated application fails, with the following error:

  Unresolved requirement: Require-Bundle: org.eclipse.ui
    -> Bundle-SymbolicName: org.eclipse.ui; bundle-version="3.108.1.v20160929-1045"; singleton:="true"
       org.eclipse.ui [56]
         Unresolved requirement: Require-Bundle: org.eclipse.ui.workbench; bundle-version="[3.105.0,4.0.0)"; visibility:="reexport"
           -> Bundle-SymbolicName: org.eclipse.ui.workbench; bundle-version="3.108.2.v20161025-2029"; singleton:="true"
              org.eclipse.ui.workbench [63]
                Unresolved requirement: Import-Package: org.eclipse.e4.ui.internal.workbench.renderers.swt
                  -> Export-Package: org.eclipse.e4.ui.internal.workbench.renderers.swt; bundle-symbolic-name="org.eclipse.e4.ui.workbench.renderers.swt"; bundle-version="0.14.0.v20160525-0940"; version="0.0.0"; x-friends:="org.eclipse.ui.workbench"
                     org.eclipse.e4.ui.workbench.renderers.swt [46]
                       Unresolved requirement: Require-Bundle: org.eclipse.e4.ui.workbench.swt; bundle-version="0.9.0"
                         -> Bundle-SymbolicName: org.eclipse.e4.ui.workbench.swt; bundle-version="0.14.1.v20160829-0832"; singleton:="true"
                            org.eclipse.e4.ui.workbench.swt [35]
                              Unresolved requirement: Require-Capability: osgi.extender; filter:="(&(osgi.extender=osgi.component)(version>=1.2)(!(version>=2.0)))"
                Unresolved requirement: Import-Package: org.eclipse.e4.ui.internal.workbench.swt
                  -> Export-Package: org.eclipse.e4.ui.internal.workbench.swt; bundle-symbolic-name="org.eclipse.e4.ui.workbench.swt"; bundle-version="0.14.1.v20160829-0832"; version="0.0.0"; x-friends:="org.eclipse.e4.ui.workbench.addons.swt,org.eclipse.e4.ui.workbench.renderers.swt,org.eclipse.ui.workbench"

The problem is also reproducible with Oxygen latest I-build I20170123
Comment 1 Vikas Chandra CLA 2017-01-24 05:08:10 EST
Lars, can you  please look at this case.
Comment 2 Vincenzo Caselli CLA 2017-01-24 05:17:19 EST
Created attachment 266427 [details]
Proposed patch

This is a proposed patch:
it adds the following 3 dependencies to all 3.x Templates:
- org.eclipse.equinox.ds
- org.eclipse.equinox.util
- org.eclipse.equinox.event

Let me know if there is a better way.
Thank you
Vincenzo
Comment 3 Lars Vogel CLA 2017-01-24 05:38:31 EST
(In reply to Vikas Chandra from comment #1)
> Lars, can you  please look at this case.

Will do, thanks.
Comment 4 Eclipse Genie CLA 2017-01-24 08:37:59 EST
New Gerrit change created: https://git.eclipse.org/r/89431
Comment 5 Vincenzo Caselli CLA 2017-01-24 17:01:31 EST
Hi Lars, Vikas,
I pushed also the same patch as a Gerrit review.
What I noticed is that for Neon the following dependencies are enough:
- org.eclipse.equinox.ds
- org.eclipse.equinox.util

But for Oxygen also 
- org.eclipse.equinox.event
is needed.

So, in the end, adding all of them is ok both for Neon and Oxygen.
Does this solution make sense for you?
Thank you
Vincenzo
Comment 6 Vikas Chandra CLA 2017-02-28 05:22:58 EST
Lars, any update on this one?
Comment 7 Vikas Chandra CLA 2017-05-04 06:56:20 EDT
Lars, any update on this one?
Comment 8 Lars Vogel CLA 2017-05-08 08:16:19 EDT
Root cause is that OSGi switch to capacities for providing events and ds. PDE should fix Bug 509436 to create the a correct launch configuration.

But as it looks like Bug 509436 will not make it into 4.7, I suggest to apply  Vincenzos fix so that the templates start out of the box.

@Vikas, I plan to test and commit the fix from  Vincenzo. Feel free to revert, if you plan to find a better solution.
Comment 10 Lars Vogel CLA 2017-05-08 08:32:47 EDT
This is a workaround for the missing functionality in PDE to support capacities.

Thanks you Vincenzo for the patch.
Comment 11 Vincenzo Caselli CLA 2017-05-08 09:14:29 EDT
Thank you Lars and Vikas!
It's always a pleasure to contribute.
Vincenzo
Comment 12 Vikas Chandra CLA 2017-05-12 04:29:37 EDT
 Vincenzo, can you please verify in latest oxygen build
Comment 13 Vincenzo Caselli CLA 2017-05-18 04:48:36 EDT
Hi Vikas,
I tested with build 
eclipse-SDK-I20170517-2000
and confirm that now all four RCP 3.x application plug-ins wizards are working successfully!
Thank you
Vincenzo