You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by Charles Moulliard <cm...@gmail.com> on 2009/09/25 13:34:05 UTC

Bundle not started immediately after a deployment : Apache karaf 1.0.0 !

I have discovered something strange. I have deployed a new bundle and
this one was not started immediately. To start it, I was oblige to use
command osgi:start

Here is a copy/paste of what I have done in karaf

1) Try to install camel-web

karaf@root> osgi:install
war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
java.net.MalformedURLException: Unknown protocol: war
karaf@root> osgi:list | grep Pax
[  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - API (1.4)
[  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - Service (1.4)
[  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
mvn: (1.0.0)
[  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
wrap: (1.0.0)
[  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
Web Container (0.6.0)
[  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
Extender - WAR (0.5.1)

I Can't install it as pax-utl-war bundle is not deployed

2) Install Pax Url War

karaf@root> install mvn:org.ops4j.pax.url/pax-url-war/1.0.0
Bundle ID: 115

3) Try to install camel-web

karaf@root> osgi:install
war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
java.net.MalformedURLException: Unknown protocol: war

3) Check bundle status

karaf@root> osgi:list | grep Pax
[  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - API (1.4)
[  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - Service (1.4)
[  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
mvn: (1.0.0)
[  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
wrap: (1.0.0)
[  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
Web Container (0.6.0)
[  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
Extender - WAR (0.5.1)
[ 115] [Resolved   ] [            ] [       ] [   60] OPS4J Pax Url -
war:, war-i: (1.0.0)

After deployment, the status of this bundle was RESOLVED and not Active

4) Start the bundle
karaf@root> osgi:start 115
karaf@root> osgi:list | grep Pax
[  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - API (1.4)
[  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
Logging - Service (1.4)
[  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
mvn: (1.0.0)
[  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
wrap: (1.0.0)
[  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
Web Container (0.6.0)
[  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
Extender - WAR (0.5.1)
[ 115] [Active     ] [            ] [       ] [   60] OPS4J Pax Url -
war:, war-i: (1.0.0)

5) Deploy camel-web

karaf@root> osgi:install
war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war



Charles Moulliard
Senior Enterprise Architect
Apache Camel Committer

*****************************
blog : http://cmoulliard.blogspot.com

Re: Bundle not started immediately after a deployment : Apache karaf 1.0.0 !

Posted by Charles Moulliard <cm...@gmail.com>.
sorry for my omission of "-s"  ;-)


Charles Moulliard
Senior Enterprise Architect
Apache Camel Committer

*****************************
blog : http://cmoulliard.blogspot.com



On Fri, Sep 25, 2009 at 1:36 PM, Guillaume Nodet <gn...@gmail.com> wrote:
> Try "osgi:install --help".
> There is a "-s" option to start the bundle.
>
> On Fri, Sep 25, 2009 at 13:34, Charles Moulliard <cm...@gmail.com> wrote:
>> I have discovered something strange. I have deployed a new bundle and
>> this one was not started immediately. To start it, I was oblige to use
>> command osgi:start
>>
>> Here is a copy/paste of what I have done in karaf
>>
>> 1) Try to install camel-web
>>
>> karaf@root> osgi:install
>> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
>> java.net.MalformedURLException: Unknown protocol: war
>> karaf@root> osgi:list | grep Pax
>> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - API (1.4)
>> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - Service (1.4)
>> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> mvn: (1.0.0)
>> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> wrap: (1.0.0)
>> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
>> Web Container (0.6.0)
>> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
>> Extender - WAR (0.5.1)
>>
>> I Can't install it as pax-utl-war bundle is not deployed
>>
>> 2) Install Pax Url War
>>
>> karaf@root> install mvn:org.ops4j.pax.url/pax-url-war/1.0.0
>> Bundle ID: 115
>>
>> 3) Try to install camel-web
>>
>> karaf@root> osgi:install
>> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
>> java.net.MalformedURLException: Unknown protocol: war
>>
>> 3) Check bundle status
>>
>> karaf@root> osgi:list | grep Pax
>> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - API (1.4)
>> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - Service (1.4)
>> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> mvn: (1.0.0)
>> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> wrap: (1.0.0)
>> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
>> Web Container (0.6.0)
>> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
>> Extender - WAR (0.5.1)
>> [ 115] [Resolved   ] [            ] [       ] [   60] OPS4J Pax Url -
>> war:, war-i: (1.0.0)
>>
>> After deployment, the status of this bundle was RESOLVED and not Active
>>
>> 4) Start the bundle
>> karaf@root> osgi:start 115
>> karaf@root> osgi:list | grep Pax
>> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - API (1.4)
>> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
>> Logging - Service (1.4)
>> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> mvn: (1.0.0)
>> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
>> wrap: (1.0.0)
>> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
>> Web Container (0.6.0)
>> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
>> Extender - WAR (0.5.1)
>> [ 115] [Active     ] [            ] [       ] [   60] OPS4J Pax Url -
>> war:, war-i: (1.0.0)
>>
>> 5) Deploy camel-web
>>
>> karaf@root> osgi:install
>> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
>>
>>
>>
>> Charles Moulliard
>> Senior Enterprise Architect
>> Apache Camel Committer
>>
>> *****************************
>> blog : http://cmoulliard.blogspot.com
>>
>
>
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com
>

Re: Bundle not started immediately after a deployment : Apache karaf 1.0.0 !

Posted by Guillaume Nodet <gn...@gmail.com>.
Try "osgi:install --help".
There is a "-s" option to start the bundle.

On Fri, Sep 25, 2009 at 13:34, Charles Moulliard <cm...@gmail.com> wrote:
> I have discovered something strange. I have deployed a new bundle and
> this one was not started immediately. To start it, I was oblige to use
> command osgi:start
>
> Here is a copy/paste of what I have done in karaf
>
> 1) Try to install camel-web
>
> karaf@root> osgi:install
> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
> java.net.MalformedURLException: Unknown protocol: war
> karaf@root> osgi:list | grep Pax
> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - API (1.4)
> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - Service (1.4)
> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> mvn: (1.0.0)
> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> wrap: (1.0.0)
> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
> Web Container (0.6.0)
> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
> Extender - WAR (0.5.1)
>
> I Can't install it as pax-utl-war bundle is not deployed
>
> 2) Install Pax Url War
>
> karaf@root> install mvn:org.ops4j.pax.url/pax-url-war/1.0.0
> Bundle ID: 115
>
> 3) Try to install camel-web
>
> karaf@root> osgi:install
> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
> java.net.MalformedURLException: Unknown protocol: war
>
> 3) Check bundle status
>
> karaf@root> osgi:list | grep Pax
> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - API (1.4)
> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - Service (1.4)
> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> mvn: (1.0.0)
> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> wrap: (1.0.0)
> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
> Web Container (0.6.0)
> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
> Extender - WAR (0.5.1)
> [ 115] [Resolved   ] [            ] [       ] [   60] OPS4J Pax Url -
> war:, war-i: (1.0.0)
>
> After deployment, the status of this bundle was RESOLVED and not Active
>
> 4) Start the bundle
> karaf@root> osgi:start 115
> karaf@root> osgi:list | grep Pax
> [  25] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - API (1.4)
> [  26] [Active     ] [            ] [       ] [    8] OPS4J Pax
> Logging - Service (1.4)
> [  27] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> mvn: (1.0.0)
> [  28] [Active     ] [            ] [       ] [    5] OPS4J Pax Url -
> wrap: (1.0.0)
> [  35] [Active     ] [            ] [       ] [   60] OPS4J Pax Web -
> Web Container (0.6.0)
> [  69] [Active     ] [            ] [       ] [   60] OPS4J Pax Web
> Extender - WAR (0.5.1)
> [ 115] [Active     ] [            ] [       ] [   60] OPS4J Pax Url -
> war:, war-i: (1.0.0)
>
> 5) Deploy camel-web
>
> karaf@root> osgi:install
> war:mvn:org.apache.camel/camel-web-standalone/2.1-SNAPSHOT/war
>
>
>
> Charles Moulliard
> Senior Enterprise Architect
> Apache Camel Committer
>
> *****************************
> blog : http://cmoulliard.blogspot.com
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com