That looks good. Could you raise a JIRA and attach your sample project please so that we can reproduce and investigate the issue.
2015-07-13 21:17 GMT+02:00 Bryan Miller <bryan.mil...@inovexcorp.com>: > The headers in karaf list ranges. Here are the Imports for the "Bundle A": > > > merlin.rest (484) > ----------------- > > Bundle-ManifestVersion = 2 > Bundle-SymbolicName = merlin.rest > Bundle-Version = 2.0.0.SNAPSHOT > Bundle-Name = merlin.rest > > Import-Service = > com.inovexcorp.merlin.explore.MerlinExploreService;multiple:=false, > com.inovexcorp.merlin.service.impl.ThreatService;multiple:=false > > Import-Package = > com.inovexcorp.merlin.explore;version="[2.0,3)", > com.inovexcorp.merlin.service.impl;version="[2.0,3)", > javax.ws.rs;version="[2.0,3)", > javax.ws.rs.core;version="[2.0,3)", > org.osgi.service.blueprint;version="[1.0.0,2.0.0)" > > > > merlin.rest (486) > ----------------- > > Bundle-ManifestVersion = 2 > Bundle-SymbolicName = merlin.rest > Bundle-Version = 1.1.0.SNAPSHOT > Bundle-Name = merlin.rest > > Import-Service = > > com.inovexcorp.merlin.explore.MerlinExploreService;availability:=optional;multiple:=false, > > com.inovexcorp.merlin.service.impl.ThreatService;availability:=optional;multiple:=false > > Import-Package = > com.inovexcorp.merlin.explore;version="[1.0,2)", > com.inovexcorp.merlin.service.impl;version="[1.0,2)", > javax.ws.rs;version="[2.0,3)", > javax.ws.rs.core;version="[2.0,3)", > org.osgi.service.blueprint;version="[1.0.0,2.0.0)" > > > > com.inovexcorp.merlin.explore and com.inovexcorp.merlin.service.impl are > "Bundles B and C" Here are the exports: > > > explore (480) > ------------- > > > Export-Package = > com.inovexcorp.merlin.explore; > uses:="org.openrdf.model, > org.openrdf.repository, > org.apache.log4j, > org.openrdf.query, > com.google.gson, > org.apache.commons.collections.map"; > version=2.0.0.SNAPSHOT > > > > explore (485) > ------------- > > Bundle-ManifestVersion = 2 > Bundle-SymbolicName = explore > Bundle-Version = 1.1.0.SNAPSHOT > Bundle-Name = explore > > Export-Package = > com.inovexcorp.merlin.explore; > uses:="org.openrdf.model, > org.openrdf.repository, > org.apache.log4j, > org.openrdf.query, > com.google.gson"; > version=1.1.0.SNAPSHOT > > > > merlin.service.impl (479) > ------------------------- > > > Bundle-ManifestVersion = 2 > Bundle-SymbolicName = merlin.service.impl > Bundle-Version = 2.0.0.SNAPSHOT > Bundle-Name = merlin.service.impl > > Export-Package = > com.inovexcorp.merlin.service.impl; > uses:="com.google.common.base, > javax.ws.rs.core, > org.openrdf.repository, > org.openrdf.model, > org.apache.log4j, > org.openrdf.query, > com.google.gson"; > version=2.0.0.SNAPSHOT > > > > merlin.service.impl (487) > ------------------------- > > > Bundle-ManifestVersion = 2 > Bundle-SymbolicName = merlin.service.impl > Bundle-Version = 1.0.0.SNAPSHOT > Bundle-Name = merlin.service.impl > > Export-Package = > com.inovexcorp.merlin.service.impl; > uses:="javax.ws.rs.core, > com.google.common.base, > org.openrdf.model, > org.openrdf.repository, > com.google.gson, > org.openrdf.query"; > version=1.0.0.SNAPSHOT > > > > > > On Fri, Jul 10, 2015 at 5:45 PM, Guillaume Nodet <gno...@apache.org> > wrote: > >> You need to use version ranges when you import packages. This will >> ensure a compatible package will be used and avoid any class cast >> exceptions. >> Your use case is quite simple and should clearly not cause any issue if >> you use correct version ranges. >> >> 2015-07-10 21:07 GMT+02:00 Bryan Miller <bryan.mil...@inovexcorp.com>: >> >>> Hello, >>> >>> I am trying to deploy multiple version of two sets of bundles and am >>> running into issues. >>> Bundle A version 1.0.0-SNAPSHOT requires: >>> Bundle B version [1,2) >>> Bundle C version [1,2) >>> >>> Bundle A version 2.0.0-SNAPSHOT requires: >>> Bundle B version [2,3) >>> Bundle C version [2,3) >>> >>> >>> When I deploy Bundle A, B, and C version 1.0.0-SNAPSHOT and Bundle A,B, >>> and C version 2.0.0-SNAPSHOT, Bundle A, regardless of version, will only >>> wire to Bundle B or C if it was the most recently deploye bundle. >>> For example if I deploy >>> Bundle A(1.0.0-SNAPSHOT), then >>> Bundle B (1.0.0-SNAPSHOT), then >>> Bundle C(1.0.0-SNAPSHOT), then >>> Bundle A(2.0.0-SNAPSHOT), then >>> Bundle B(2.0.0-SNAPSHOT), then >>> Bundle C(2.0.0-SNAPSHOT) >>> >>> This causes Bundle A(2.0.0-SNAPSHOT) to work, and Bundle >>> A(1.0.0-SNAPSHOT) to give class cast exceptions. This also happens in >>> reverse, if the 2.0.0-SNAPSHOT bundles are deployed first, the >>> 1.0.0-SNAPSHOT bundles work and the 2.0.0-SNAPSHOT bundles have class cast >>> exceptions. >>> >>> -- >>> >>> *Bryan Miller* >>> >>> >>> >> > > > -- > > *Bryan Miller* > >