felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guo Du <mrdu...@gmail.com>
Subject Re: Less restrictive conflict resolution for fragment imports
Date Wed, 16 Dec 2009 10:25:50 GMT
On Wed, Dec 16, 2009 at 12:54 AM,  <Andreas.Schlosser@sybase.com> wrote:
> Hi,
>
> I found that Felix is validating the compatibility of host vs. fragment
> imports by ensuring that in case host and fragment are importing the same
> package, they should use the exactly same version (range). I believe that
> this is a little too restrictive and Felix should also allow the host
> bundle to be more restrictive on the version range than the fragment. This
> way, it is still guaranteed that the fragment will run with using the
> version range from the host bundle (which is a subset of the fragment
> version range in this case).
>
> I just ran into this problem when trying to use the Hibernate +
> Annotations bundles packaged by SpringSource. Hibernate Annotations is a
> fragment bundle, hosted by the Hibernate bundle. Hibernate imports
> org.dom4j;version="[1.6.1, 1.7.0)" whereas the fragment imports
> org.dom4j;version="[1.6.1, 2.0.0)" and the current implementation does not
> allow this fragment to be linked to its host.
>
> What do you think?

+1

I have this problem with spring-osgi-extender as well. For fragment,
we may enable the fragment when there are common set between host
version and fragment version.

Host version [2.0.0,3.0.0)
Fail fragment versions [1.0.0], [1.0.0,2.0.0), [3.0.0]
Pass fragment versions [1.0.0,5.0.0), [2.5.0,2.9.0)

Any drawback to this approach?

-Guo

Mime
View raw message