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

Bug 333006

Summary: o.e.core.resources no longer builds against a 3.6 platform
Product: [Eclipse Project] Platform Reporter: James Blackburn <jamesblackburn+eclipse>
Component: ResourcesAssignee: Platform-Resources-Inbox <platform-resources-inbox>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: john.arthorne, remy.suen, Szymon.Brandys
Version: 3.7   
Target Milestone: 3.7 M5   
Hardware: PC   
OS: Linux-GTK   
Whiteboard:

Description James Blackburn CLA 2010-12-21 07:17:15 EST
ResourcesPlugin.java commit 1.57 bumped core.resources to require new functionality in org.osgi.framework.* not present in org.eclipse.osgi_3.6.0.

In particular:
  ServiceRegistration isn't parameterized
  BundleContext.registerService doesn't take a class as the first argument

What's odd is that the problem is only reported at compile time on the class, not as a version constraint on the core.resources bundle.

As this is the only class affected, can we continue to support 3.6 for the moment?
Should core.resources have an explicit dependency on org.eclipse.osgi?
Comment 1 Szymon Brandys CLA 2010-12-21 11:03:37 EST
(In reply to comment #0)
> As this is the only class affected, can we continue to support 3.6 for the
> moment?
> Should core.resources have an explicit dependency on org.eclipse.osgi?

core.resources depends on core.runtime [3.2.0, 4.0.0). core.runtime 3.2.0 reexports org.eclipse.osgi [3.2.0, 4.0.0]. For me it means that core.resources can't use API from org.eclipse.osgi newer than 3.2.0.

If you are on Eclipse SDK 3.7, you will not see any error when core.resources starts using API from past-3.2.0 osgi. Better tooling would help here.

Anyway adding an explicit dependency to osgi looks fine. I would also change the core.runtime dependency range to [3.6.100, 4.0.0). It is unlikely that core.resources may still work on core.runtime 3.2.0.
Comment 2 Szymon Brandys CLA 2010-12-21 11:10:41 EST
Versions range is incremented by John. core.resources in 3.7 depends on core.runtime [3.7, 4.0). core.runtime reexports org.eclipse.osgi [3.7, 4.0) what fixes the problem.