On May 6, 2010, at 11:25 AM, David Bosschaert wrote:

>>> Here's a really short summary of some of the content...
>>> * Let's say you have an interface X version 1.2 that you modify to
>>> include a new method. This would break backwards compatibility for
>>> people who implement this interface. Whether this will bump the
>>> version to 1.3 or 2.0 depends on who typically implements this
>>> interface:
>>>  + If the interface is normally implemented by framework implementors
>>> (including compendium spec implementors), the version should bump to
>>> 1.3. This is because the new interface is still compatible with users
>>> of it.
>>>  + If the interface is normally implemented by user bundles, the
>>> version should bump to 2.0 as the change is likely to change user
>>> builds.
>> 
>> Maybe I misunderstand this, but I thought that recent bnd's (not yet in 
>> maven-bundle-plugin despite my best efforts) were based on the idea that 
>> you'd bump the version to 1.3, and
>> - using bundles would import with a version range of [1.2,2)
>> - implementing bundles would import with a version range of [1.2,1.3)
> 
> True, but the missing piece of information here is that using bundles
> sometimes also implement an interface (the Whiteboard Pattern). Take
> for example the Configuration Admin Service org.osgi.service.cm
> package version 1.3. In there you find a ConfigurationAdmin interface
> which is implemented by framework/spec implementors, while its
> ManagedService is implemented by users. Hence adding a method to the
> ConfigurationAdmin interface will only change the version of the
> package to 1.4. But adding a method to ManagedService will change it
> to 2.0


I can see a couple possible ways around this:
1. Claim that this package was not designed properly and should be 2 packages, 
one containing ConfigurationAdmin and one containing ManagedService which can 
then be versioned independently

2. Refine ones understanding of package versions for implementors so that major 
version bump means "we took some methods/interfaces out" and minor version 
means "we added some new methods" which seems to be what Peter's version 
policies imply.

(2) seems more reasonable to me, but I'm at the point where I need a bunch of 
simple concrete examples I can look at to believe anything in this area.

thanks
david jencks
> 
> Best regards,
> 
> David

Reply via email to