Community
Participate
Working Groups
With Bug 481449 it was tried to make the SCR implementation exchangeable. Unfortunately this doesn't work with Eclipse RCP applications. The reason is one of the most discussed dependency issues in OSGi: Require-Bundle vs. Import-Package If I remove equinox.ds from the run configuration and add felix.scr I get a "Uses constraint violation" org.eclipse.e4.ui.workbench.swt has a dependency defined to org.eclipse.osgi.services, which exposes org.osgi.service.component. The same is exportet by org.apache.felix.scr. The org.eclipse.osgi.service bundle seems to provide the collected available service interfaces from the compendium. org.apache.felix.scr provides the same especially for compendium. We really need to get better in specifying dependencies to OSGi stuff and NEVER Require-Bundle org.eclipse.osgi.services and probably not even org.eclipse.osgi. As I have something running to test, I will try to provide a patch for this. For completeness, here is one part of the quite long error message from the resolver: Uses constraint violation. Unable to resolve resource org.eclipse.e4.ui.workbench.swt [osgi.identity; type="osgi.bundle"; version:Version="0.14.0.v20160518-1929"; osgi.identity="org.eclipse.e4.ui.workbench.swt"; singleton:="true"] because it is exposed to package 'org.osgi.service.component' from resources org.eclipse.osgi.services [osgi.identity; type="osgi.bundle"; version:Version="3.5.100.v20160504-1419"; osgi.identity="org.eclipse.osgi.services"] and org.apache.felix.scr [osgi.identity; osgi.identity="org.apache.felix.scr"; type="osgi.bundle"; version:Version="2.0.2"] via two dependency chains.
New Gerrit change created: https://git.eclipse.org/r/75780
I replaced require bundle with import package for the platform bundles where I have found them. All of them simply have that dependency because of org.osgi.service.event. I didn't touch the test plugins yet, as there is still the dependency issue pending regarding tycho surefire tests. This needs to be cleaned up first. Afterwards we should also create a ticket to cleanup the dependencies in general. I have found some unused dependencies and IMHO that should be cleaned up aswell.
Gerrit change https://git.eclipse.org/r/75780 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=dc454c87ec767280ae53ab129883e6c2d8dd034b
Fixed with applied patch to change Require-Bundle org.eclipse.osgi.services to Import-Package for org.osgi.service.event
> Unfortunately this doesn't work with Eclipse RCP applications. I think that is N&N for RCP customers. Dirk, can you add this to the N&N M1?