You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Benson Margulies <be...@basistech.com> on 2016/09/28 15:28:48 UTC

Does SCR have to start before the bundles with services?

I'm trying to retrofit SCR/DS into a very dumb application that loads
some bundles and starts the framework. Everything is at the same start
level, and no @Components are ever activated.

I have logging working; I see

191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
with globalExtender setting: false
195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6

In a more sophisticated cousin of this, I carefully start SCR and DS
at one start level, and only after they are started do I get involved
in starting the rest. I wonder: is this in fact a requirement, or
should I look for some other explanation of why the dumber app is not
activating anything.

If I start up a container to a shell command line everything works
fine, so I can't get any diagnostic traction that way.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Does SCR have to start before the bundles with services?

Posted by Benson Margulies <be...@basistech.com>.
On Thu, Sep 29, 2016 at 2:34 AM, David Jencks
<da...@yahoo.com.invalid> wrote:
> Neither this nor restarting the framework should cause problems.
>
> Can you come up with a self contained demonstration of this (no components) behavior?  I vaguely recall someone having a similar problem that I couldn’t reproduce.

David,

First, a Maven bug caused me to use version 6.0.0 instead of version
6.0.1-SNAPSHOT, which led to wiring errors, which led to services not
starting.

Then, I discovered that if you really use the osgi-over-slf4j
connector properly, SCR produces messages at more than one logging
level, and I didn't have my logging back end configured correctly.

Working backwards, fixing the logging revealed the rest, and now all is well.
thanks,
benson



>
> thanks
> david jencks
>
>> On Sep 28, 2016, at 8:50 AM, Benson Margulies <be...@basistech.com> wrote:
>>
>> On Wed, Sep 28, 2016 at 11:43 AM, David Jencks
>> <david_jencks@yahoo.com.invalid <ma...@yahoo.com.invalid>> wrote:
>>> It should work in any order.
>>
>> OK, then I've got some other problem on my hands. Does the last of
>> these three messages indicate a problem?
>>
>> 177  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
>> with globalExtender setting: false
>> 181  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
>> 242  [CM Configuration Updater (ManagedService Update:
>> pid=[org.apache.felix.scr.ScrService])] ERROR
>> org.apache.felix.scr.2.0.6  - Cannot create MetaType providing
>> ManagedService; not providing Metatype information but just accepting
>> configuration
>>
>>
>>
>>
>>>
>>> david jencks
>>>
>>>> On Sep 28, 2016, at 8:28 AM, Benson Margulies <be...@basistech.com> wrote:
>>>>
>>>> I'm trying to retrofit SCR/DS into a very dumb application that loads
>>>> some bundles and starts the framework. Everything is at the same start
>>>> level, and no @Components are ever activated.
>>>>
>>>> I have logging working; I see
>>>>
>>>> 191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
>>>> with globalExtender setting: false
>>>> 195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
>>>>
>>>> In a more sophisticated cousin of this, I carefully start SCR and DS
>>>> at one start level, and only after they are started do I get involved
>>>> in starting the rest. I wonder: is this in fact a requirement, or
>>>> should I look for some other explanation of why the dumber app is not
>>>> activating anything.
>>>>
>>>> If I start up a container to a shell command line everything works
>>>> fine, so I can't get any diagnostic traction that way.
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org <ma...@felix.apache.org>
>> For additional commands, e-mail: users-help@felix.apache.org <ma...@felix.apache.org>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Does SCR have to start before the bundles with services?

Posted by David Jencks <da...@yahoo.com.INVALID>.
Neither this nor restarting the framework should cause problems.

Can you come up with a self contained demonstration of this (no components) behavior?  I vaguely recall someone having a similar problem that I couldn’t reproduce.

thanks
david jencks

> On Sep 28, 2016, at 8:50 AM, Benson Margulies <be...@basistech.com> wrote:
> 
> On Wed, Sep 28, 2016 at 11:43 AM, David Jencks
> <david_jencks@yahoo.com.invalid <ma...@yahoo.com.invalid>> wrote:
>> It should work in any order.
> 
> OK, then I've got some other problem on my hands. Does the last of
> these three messages indicate a problem?
> 
> 177  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
> with globalExtender setting: false
> 181  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
> 242  [CM Configuration Updater (ManagedService Update:
> pid=[org.apache.felix.scr.ScrService])] ERROR
> org.apache.felix.scr.2.0.6  - Cannot create MetaType providing
> ManagedService; not providing Metatype information but just accepting
> configuration
> 
> 
> 
> 
>> 
>> david jencks
>> 
>>> On Sep 28, 2016, at 8:28 AM, Benson Margulies <be...@basistech.com> wrote:
>>> 
>>> I'm trying to retrofit SCR/DS into a very dumb application that loads
>>> some bundles and starts the framework. Everything is at the same start
>>> level, and no @Components are ever activated.
>>> 
>>> I have logging working; I see
>>> 
>>> 191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
>>> with globalExtender setting: false
>>> 195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
>>> 
>>> In a more sophisticated cousin of this, I carefully start SCR and DS
>>> at one start level, and only after they are started do I get involved
>>> in starting the rest. I wonder: is this in fact a requirement, or
>>> should I look for some other explanation of why the dumber app is not
>>> activating anything.
>>> 
>>> If I start up a container to a shell command line everything works
>>> fine, so I can't get any diagnostic traction that way.
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>> 
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org <ma...@felix.apache.org>
> For additional commands, e-mail: users-help@felix.apache.org <ma...@felix.apache.org>

Re: Does SCR have to start before the bundles with services?

Posted by Benson Margulies <be...@basistech.com>.
On Wed, Sep 28, 2016 at 11:50 AM, Benson Margulies <be...@basistech.com> wrote:
> On Wed, Sep 28, 2016 at 11:43 AM, David Jencks
> <da...@yahoo.com.invalid> wrote:
>> It should work in any order.

The only other thing I can think of is this: in the application I'm
working with, the code starts the framework, loads bundles, stops the
framework, then starts it again.

>
> OK, then I've got some other problem on my hands. Does the last of
> these three messages indicate a problem?
>
> 177  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
> with globalExtender setting: false
> 181  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
> 242  [CM Configuration Updater (ManagedService Update:
> pid=[org.apache.felix.scr.ScrService])] ERROR
> org.apache.felix.scr.2.0.6  - Cannot create MetaType providing
> ManagedService; not providing Metatype information but just accepting
> configuration
>
>
>
>
>>
>> david jencks
>>
>>> On Sep 28, 2016, at 8:28 AM, Benson Margulies <be...@basistech.com> wrote:
>>>
>>> I'm trying to retrofit SCR/DS into a very dumb application that loads
>>> some bundles and starts the framework. Everything is at the same start
>>> level, and no @Components are ever activated.
>>>
>>> I have logging working; I see
>>>
>>> 191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
>>> with globalExtender setting: false
>>> 195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
>>>
>>> In a more sophisticated cousin of this, I carefully start SCR and DS
>>> at one start level, and only after they are started do I get involved
>>> in starting the rest. I wonder: is this in fact a requirement, or
>>> should I look for some other explanation of why the dumber app is not
>>> activating anything.
>>>
>>> If I start up a container to a shell command line everything works
>>> fine, so I can't get any diagnostic traction that way.
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Does SCR have to start before the bundles with services?

Posted by Benson Margulies <be...@basistech.com>.
On Wed, Sep 28, 2016 at 11:43 AM, David Jencks
<da...@yahoo.com.invalid> wrote:
> It should work in any order.

OK, then I've got some other problem on my hands. Does the last of
these three messages indicate a problem?

177  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
with globalExtender setting: false
181  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
242  [CM Configuration Updater (ManagedService Update:
pid=[org.apache.felix.scr.ScrService])] ERROR
org.apache.felix.scr.2.0.6  - Cannot create MetaType providing
ManagedService; not providing Metatype information but just accepting
configuration




>
> david jencks
>
>> On Sep 28, 2016, at 8:28 AM, Benson Margulies <be...@basistech.com> wrote:
>>
>> I'm trying to retrofit SCR/DS into a very dumb application that loads
>> some bundles and starts the framework. Everything is at the same start
>> level, and no @Components are ever activated.
>>
>> I have logging working; I see
>>
>> 191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
>> with globalExtender setting: false
>> 195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
>>
>> In a more sophisticated cousin of this, I carefully start SCR and DS
>> at one start level, and only after they are started do I get involved
>> in starting the rest. I wonder: is this in fact a requirement, or
>> should I look for some other explanation of why the dumber app is not
>> activating anything.
>>
>> If I start up a container to a shell command line everything works
>> fine, so I can't get any diagnostic traction that way.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Does SCR have to start before the bundles with services?

Posted by David Jencks <da...@yahoo.com.INVALID>.
It should work in any order.

david jencks

> On Sep 28, 2016, at 8:28 AM, Benson Margulies <be...@basistech.com> wrote:
> 
> I'm trying to retrofit SCR/DS into a very dumb application that loads
> some bundles and starts the framework. Everything is at the same start
> level, and no @Components are ever activated.
> 
> I have logging working; I see
> 
> 191  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  - Starting
> with globalExtender setting: false
> 195  [FelixStartLevel] INFO  org.apache.felix.scr.2.0.6  -  Version = 2.0.6
> 
> In a more sophisticated cousin of this, I carefully start SCR and DS
> at one start level, and only after they are started do I get involved
> in starting the rest. I wonder: is this in fact a requirement, or
> should I look for some other explanation of why the dumber app is not
> activating anything.
> 
> If I start up a container to a shell command line everything works
> fine, so I can't get any diagnostic traction that way.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org