What if you skip the OBR part and drop the two bundle in the 'deploy'
directory? Or even use the bundle:install command?

2015-05-11 20:20 GMT+02:00 Stephen Kahmann <stephen.kahm...@inovexcorp.com>:

>  My thoughts exactly! :-)
>
>  From my previous example, you can see that 2.7 is active, and when I
> “install” 2.8, Karaf doesn’t actually install it. Karaf seems to see that
> 2.7 is active and just skips installing 2.8.
>
>  Then later, I installed and activated 2.8 then tried to install 2.7 via
> OBR and the OBR feature *replaced* my active 2.8 bundle as shown below:
>
>   *karaf*@root()> list | grep Open
>
> 283 | Active    |  80 | 2.8.1                                     | OpenRDF
> Sesame: Runtime - OSGi
>
> *karaf*@root()> obr:deploy org.openrdf.sesame2
>
> Target resource(s):
>
> -------------------
>
>    OpenRDF Sesame: Runtime - OSGi (2.7.14)
>
>
>  Deploying...done.
>
> *karaf*@root()> list | grep Open
>
> 283 | Active    |  80 | 2.7.14                                    | OpenRDF
> Sesame: Runtime - OSGi
>
>  Needless to say this is very frustrating. To me they both look like
> bugs, but I wasn’t sure if this was known behavior.
>
>  Thank you!
>
>   From: Charlie Mordant <cmorda...@gmail.com>
> Reply-To: "user@karaf.apache.org" <user@karaf.apache.org>
> Date: Monday, May 11, 2015 at 2:12 PM
> To: "user@karaf.apache.org" <user@karaf.apache.org>
> Subject: Re: Install two versions of same bundle
>
>   Hi,
>
>  Should work, OSGI is done for this! Is OpenRDF 2.8.x started?
>
>  Regards,
>
> 2015-05-11 18:46 GMT+02:00 Stephen Kahmann <stephen.kahm...@inovexcorp.com
> >:
>
>>  Hi,
>>
>>  I need to install two versions of a bundle. One version is 2.7.14 and
>> the other is 2.8.1. These bundles do no follow semantic versioning so 2.8
>> is not backwards compatible. Some of my bundles require 2.7 and some
>> require 2.8. The headers are set correctly for both. The problem is that I
>> cannot install 2.8 when 2.7 is already installed. Is this a bug or expected
>> behavior?
>>
>>   *karaf*@root()> list | grep OpenRDF
>>
>> 195 | Active    |  80 | 2.7.14                                    |
>> OpenRDF Sesame: Runtime - OSGi
>>
>> *karaf*@root()> install
>> file:/Users/user/lib/apache-karaf-3.0.3/deploy/sesame-runtime-osgi-2.8.1.jar
>>
>> Bundle ID: 195
>>
>> *karaf*@root()> list | grep OpenRDF
>>
>> 195 | Active    |  80 | 2.7.14                                    |
>> OpenRDF Sesame: Runtime – OSGi
>>
>> *karaf*@root()> start 198
>>
>> Error executing command: Error executing command on bundles:
>>
>>  Unable to execute command on bundle 198: Unresolved constraint in
>> bundle com.example.bundle [198]: Unable to resolve 198.0: missing
>> requirement [198.0] osgi.wiring.package;
>> (&(osgi.wiring.package=com.com.example.bundle.api)(version>=1.0.0)(!(version>=2.0.0)))
>> [caused by: Unable to resolve 194.0: missing requirement [194.0]
>> osgi.wiring.package;
>> (&(osgi.wiring.package=org.openrdf.repository)(version>=2.8.0)(!(version>=3.0.0)))]
>>
>>  Thanks
>>
>
>
>
>  --
>  Charlie Mordant
>
> Full OSGI/EE stack made with Karaf:
> https://github.com/OsgiliathEnterprise/net.osgiliath.parent
>



-- 
Charlie Mordant

Full OSGI/EE stack made with Karaf:
https://github.com/OsgiliathEnterprise/net.osgiliath.parent

Reply via email to