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 2014/12/09 00:07:30 UTC

Framework#start versus FrameworkStartLevel#setStartLevel

FrameworkStartLevel#setStartLevel takes listeners, which looks really
useful. Can I call it instead of Framework#start?

Re: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by Benson Margulies <be...@basistech.com>.
On Tue, Dec 9, 2014 at 8:16 AM, Richard S. Hall <he...@ungoverned.org> wrote:
> On 12/9/14 01:55 , Felix Meschberger wrote:
>>
>> Hi
>>
>>> Am 09.12.2014 um 03:02 schrieb Richard Hall <he...@ungoverned.org>:
>>>
>>> On 12/8/14 20:47 , Benson Margulies wrote:
>>>>
>>>> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org>
>>>> wrote:
>>>>>
>>>>> On 12/8/14 18:07 , Benson Margulies wrote:
>>>>>>
>>>>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>>>>>> useful. Can I call it instead of Framework#start?
>>>>>
>>>>> They don't do the same thing, but certainly you can use either...
>>>>
>>>> That's what I'm trying to sort out. To be perfectly clear about my
>>>> ignorance, I don't understand what the FrameworkStartLevel method is
>>>> for if it's not another way to express the Framework method.
>>>>
>>>> Here's what I have working:
>>>>
>>>> 1. framework.init();
>>>> 2. obtain default bundle start level from FrameworkStartLevel
>>>> 3. installBundle all bundles
>>>> 4. set start level for each bundle by adapting to a BundleStartLevel
>>>> 5. start all bundles
>>>> 6. framework.start
>>>>
>>>> So, where would FrameworkStartLevel#setStartLevel fit into all this?
>>>> Is it only useful if I need to change the start level after
>>>> framework.start()?
>>>
>>> Yeah, it is pretty much only useful after you activate the framework
>>> (i.e., call start()). Although, after a quick look, I'm not 100% certain
>>> what the Felix framework implementation will do if you call setStartLevel()
>>> before calling start()…
>>
>> My interpretation is, that the init() method sets the StartLevel service
>> up and then calling setStartLevel instead of Framework.start() would
>> probably start the framework except: The framework STARTED event would not
>> be sent !
>
>
> Yes, that was sort of my interpretation of looking at the code too, but I'm
> not convinced that that is the correct behavior.

I'm not interested in subverting the API, but rather understanding the
thought process of the structure. The spec is unclear about what
happens if you set the 'begin' level to 0. Would that cause start() to
leave the start level alone? In any case, it seems to me to be a bit
of an asymmetry that the one method takes 'for the duration' listeners
and the other doesn't, and my idea about using start level 2 is an
unambiguous way to take advantage of those listeners. Or, add a
listener that bops a countdown latch, call start(), wait on the latch.


>
> -> richard
>
>>
>> It would really stick to the original intent, as I read it: Use
>> Framework.start() to start the framework and use
>> FrameworkStartLevel.setStartLevel to change the current start level.
>>
>> Regards
>> Felix
>>
>>> -> richard
>>>
>>>>
>>>>
>>>>
>>>>
>>>>> -> richard
>>>>>
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> 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
>>>
>>
>> ---------------------------------------------------------------------
>> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by "Richard S. Hall" <he...@ungoverned.org>.
On 12/9/14 08:16 , Richard S. Hall wrote:
> On 12/9/14 01:55 , Felix Meschberger wrote:
>> Hi
>>
>>> Am 09.12.2014 um 03:02 schrieb Richard Hall <he...@ungoverned.org>:
>>>
>>> On 12/8/14 20:47 , Benson Margulies wrote:
>>>> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall 
>>>> <he...@ungoverned.org> wrote:
>>>>> On 12/8/14 18:07 , Benson Margulies wrote:
>>>>>> FrameworkStartLevel#setStartLevel takes listeners, which looks 
>>>>>> really
>>>>>> useful. Can I call it instead of Framework#start?
>>>>> They don't do the same thing, but certainly you can use either...
>>>> That's what I'm trying to sort out. To be perfectly clear about my
>>>> ignorance, I don't understand what the FrameworkStartLevel method is
>>>> for if it's not another way to express the Framework method.
>>>>
>>>> Here's what I have working:
>>>>
>>>> 1. framework.init();
>>>> 2. obtain default bundle start level from FrameworkStartLevel
>>>> 3. installBundle all bundles
>>>> 4. set start level for each bundle by adapting to a BundleStartLevel
>>>> 5. start all bundles
>>>> 6. framework.start
>>>>
>>>> So, where would FrameworkStartLevel#setStartLevel fit into all this?
>>>> Is it only useful if I need to change the start level after
>>>> framework.start()?
>>> Yeah, it is pretty much only useful after you activate the framework 
>>> (i.e., call start()). Although, after a quick look, I'm not 100% 
>>> certain what the Felix framework implementation will do if you call 
>>> setStartLevel() before calling start()…
>> My interpretation is, that the init() method sets the StartLevel 
>> service up and then calling setStartLevel instead of 
>> Framework.start() would probably start the framework except: The 
>> framework STARTED event would not be sent !
>
> Yes, that was sort of my interpretation of looking at the code too, 
> but I'm not convinced that that is the correct behavior.

I think we need to check for being in INIT state and throw an illegal 
state exception or something...

-> richard

>
> -> richard
>
>>
>> It would really stick to the original intent, as I read it: Use 
>> Framework.start() to start the framework and use 
>> FrameworkStartLevel.setStartLevel to change the current start level.
>>
>> Regards
>> Felix
>>
>>> -> richard
>>>
>>>>
>>>>
>>>>
>>>>
>>>>> -> richard
>>>>>
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> 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
>>>
>>
>> ---------------------------------------------------------------------
>> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by "Richard S. Hall" <he...@ungoverned.org>.
On 12/9/14 01:55 , Felix Meschberger wrote:
> Hi
>
>> Am 09.12.2014 um 03:02 schrieb Richard Hall <he...@ungoverned.org>:
>>
>> On 12/8/14 20:47 , Benson Margulies wrote:
>>> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org> wrote:
>>>> On 12/8/14 18:07 , Benson Margulies wrote:
>>>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>>>>> useful. Can I call it instead of Framework#start?
>>>> They don't do the same thing, but certainly you can use either...
>>> That's what I'm trying to sort out. To be perfectly clear about my
>>> ignorance, I don't understand what the FrameworkStartLevel method is
>>> for if it's not another way to express the Framework method.
>>>
>>> Here's what I have working:
>>>
>>> 1. framework.init();
>>> 2. obtain default bundle start level from FrameworkStartLevel
>>> 3. installBundle all bundles
>>> 4. set start level for each bundle by adapting to a BundleStartLevel
>>> 5. start all bundles
>>> 6. framework.start
>>>
>>> So, where would FrameworkStartLevel#setStartLevel fit into all this?
>>> Is it only useful if I need to change the start level after
>>> framework.start()?
>> Yeah, it is pretty much only useful after you activate the framework (i.e., call start()). Although, after a quick look, I'm not 100% certain what the Felix framework implementation will do if you call setStartLevel() before calling start()…
> My interpretation is, that the init() method sets the StartLevel service up and then calling setStartLevel instead of Framework.start() would probably start the framework except: The framework STARTED event would not be sent !

Yes, that was sort of my interpretation of looking at the code too, but 
I'm not convinced that that is the correct behavior.

-> richard

>
> It would really stick to the original intent, as I read it: Use Framework.start() to start the framework and use FrameworkStartLevel.setStartLevel to change the current start level.
>
> Regards
> Felix
>
>> -> richard
>>
>>>
>>>
>>>
>>>
>>>> -> richard
>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> 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
>>
>
> ---------------------------------------------------------------------
> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by Felix Meschberger <fm...@adobe.com>.
Hi

> Am 09.12.2014 um 03:02 schrieb Richard Hall <he...@ungoverned.org>:
> 
> On 12/8/14 20:47 , Benson Margulies wrote:
>> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org> wrote:
>>> On 12/8/14 18:07 , Benson Margulies wrote:
>>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>>>> useful. Can I call it instead of Framework#start?
>>> 
>>> They don't do the same thing, but certainly you can use either...
>> 
>> That's what I'm trying to sort out. To be perfectly clear about my
>> ignorance, I don't understand what the FrameworkStartLevel method is
>> for if it's not another way to express the Framework method.
>> 
>> Here's what I have working:
>> 
>> 1. framework.init();
>> 2. obtain default bundle start level from FrameworkStartLevel
>> 3. installBundle all bundles
>> 4. set start level for each bundle by adapting to a BundleStartLevel
>> 5. start all bundles
>> 6. framework.start
>> 
>> So, where would FrameworkStartLevel#setStartLevel fit into all this?
>> Is it only useful if I need to change the start level after
>> framework.start()?
> 
> Yeah, it is pretty much only useful after you activate the framework (i.e., call start()). Although, after a quick look, I'm not 100% certain what the Felix framework implementation will do if you call setStartLevel() before calling start()…

My interpretation is, that the init() method sets the StartLevel service up and then calling setStartLevel instead of Framework.start() would probably start the framework except: The framework STARTED event would not be sent !

It would really stick to the original intent, as I read it: Use Framework.start() to start the framework and use FrameworkStartLevel.setStartLevel to change the current start level.

Regards
Felix

> 
> -> richard
> 
>> 
>> 
>> 
>> 
>> 
>>> 
>>> -> richard
>>> 
>>> 
>>> 
>>> ---------------------------------------------------------------------
>>> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by "Richard S. Hall" <he...@ungoverned.org>.
On 12/8/14 21:24 , Richard Hall wrote:
>
> I think that would work, although I think you can also configure the 
> initial framework start level too.
>

Also, I'm not sure what synchronization you are trying to achieve, but 
calling Framework.start() is not asynchronous, so calling it waits until 
all start levels up to the initial start level have completed activating.

-> richard

> On Dec 8, 2014 9:10 PM, "Benson Margulies" <benson@basistech.com 
> <ma...@basistech.com>> wrote:
>
>     On Mon, Dec 8, 2014 at 9:02 PM, Richard S. Hall
>     <heavy@ungoverned.org <ma...@ungoverned.org>> wrote:
>     > On 12/8/14 20:47 , Benson Margulies wrote:
>     >>
>     >> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall
>     <heavy@ungoverned.org <ma...@ungoverned.org>>
>     >> wrote:
>     >>>
>     >>> On 12/8/14 18:07 , Benson Margulies wrote:
>     >>>>
>     >>>> FrameworkStartLevel#setStartLevel takes listeners, which
>     looks really
>     >>>> useful. Can I call it instead of Framework#start?
>     >>>
>     >>>
>     >>> They don't do the same thing, but certainly you can use either...
>     >>
>     >>
>     >> That's what I'm trying to sort out. To be perfectly clear about my
>     >> ignorance, I don't understand what the FrameworkStartLevel
>     method is
>     >> for if it's not another way to express the Framework method.
>     >>
>     >> Here's what I have working:
>     >>
>     >> 1. framework.init();
>     >> 2. obtain default bundle start level from FrameworkStartLevel
>     >> 3. installBundle all bundles
>     >> 4. set start level for each bundle by adapting to a
>     BundleStartLevel
>     >> 5. start all bundles
>     >> 6. framework.start
>     >>
>     >> So, where would FrameworkStartLevel#setStartLevel fit into all
>     this?
>     >> Is it only useful if I need to change the start level after
>     >> framework.start()?
>     >
>     >
>     > Yeah, it is pretty much only useful after you activate the
>     framework (i.e.,
>     > call start()). Although, after a quick look, I'm not 100%
>     certain what the
>     > Felix framework implementation will do if you call
>     setStartLevel() before
>     > calling start()...
>
>     So, if I set all the bundles to start at 2, and leave the beginning
>     level at 1, then start() won't start any bundles. Then I could call
>     setStartLevel(2, myFavoriteListener) and achieve synchronization?
>
>
>     >
>     > -> richard
>     >
>     >
>     >>
>     >>
>     >>
>     >>
>     >>
>     >>>
>     >>> -> richard
>     >>>
>     >>>
>     >>>
>     >>>
>     ---------------------------------------------------------------------
>     >>> 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
>     <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
>     <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
>     <ma...@felix.apache.org>
>     For additional commands, e-mail: users-help@felix.apache.org
>     <ma...@felix.apache.org>
>


Re: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by Richard Hall <he...@ungoverned.org>.
I think that would work, although I think you can also configure the
initial framework start level too.
On Dec 8, 2014 9:10 PM, "Benson Margulies" <be...@basistech.com> wrote:

> On Mon, Dec 8, 2014 at 9:02 PM, Richard S. Hall <he...@ungoverned.org>
> wrote:
> > On 12/8/14 20:47 , Benson Margulies wrote:
> >>
> >> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org>
> >> wrote:
> >>>
> >>> On 12/8/14 18:07 , Benson Margulies wrote:
> >>>>
> >>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
> >>>> useful. Can I call it instead of Framework#start?
> >>>
> >>>
> >>> They don't do the same thing, but certainly you can use either...
> >>
> >>
> >> That's what I'm trying to sort out. To be perfectly clear about my
> >> ignorance, I don't understand what the FrameworkStartLevel method is
> >> for if it's not another way to express the Framework method.
> >>
> >> Here's what I have working:
> >>
> >> 1. framework.init();
> >> 2. obtain default bundle start level from FrameworkStartLevel
> >> 3. installBundle all bundles
> >> 4. set start level for each bundle by adapting to a BundleStartLevel
> >> 5. start all bundles
> >> 6. framework.start
> >>
> >> So, where would FrameworkStartLevel#setStartLevel fit into all this?
> >> Is it only useful if I need to change the start level after
> >> framework.start()?
> >
> >
> > Yeah, it is pretty much only useful after you activate the framework
> (i.e.,
> > call start()). Although, after a quick look, I'm not 100% certain what
> the
> > Felix framework implementation will do if you call setStartLevel() before
> > calling start()...
>
> So, if I set all the bundles to start at 2, and leave the beginning
> level at 1, then start() won't start any bundles. Then I could call
> setStartLevel(2, myFavoriteListener) and achieve synchronization?
>
>
> >
> > -> richard
> >
> >
> >>
> >>
> >>
> >>
> >>
> >>>
> >>> -> richard
> >>>
> >>>
> >>>
> >>> ---------------------------------------------------------------------
> >>> 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
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>

Re: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by Benson Margulies <be...@basistech.com>.
On Mon, Dec 8, 2014 at 9:02 PM, Richard S. Hall <he...@ungoverned.org> wrote:
> On 12/8/14 20:47 , Benson Margulies wrote:
>>
>> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org>
>> wrote:
>>>
>>> On 12/8/14 18:07 , Benson Margulies wrote:
>>>>
>>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>>>> useful. Can I call it instead of Framework#start?
>>>
>>>
>>> They don't do the same thing, but certainly you can use either...
>>
>>
>> That's what I'm trying to sort out. To be perfectly clear about my
>> ignorance, I don't understand what the FrameworkStartLevel method is
>> for if it's not another way to express the Framework method.
>>
>> Here's what I have working:
>>
>> 1. framework.init();
>> 2. obtain default bundle start level from FrameworkStartLevel
>> 3. installBundle all bundles
>> 4. set start level for each bundle by adapting to a BundleStartLevel
>> 5. start all bundles
>> 6. framework.start
>>
>> So, where would FrameworkStartLevel#setStartLevel fit into all this?
>> Is it only useful if I need to change the start level after
>> framework.start()?
>
>
> Yeah, it is pretty much only useful after you activate the framework (i.e.,
> call start()). Although, after a quick look, I'm not 100% certain what the
> Felix framework implementation will do if you call setStartLevel() before
> calling start()...

So, if I set all the bundles to start at 2, and leave the beginning
level at 1, then start() won't start any bundles. Then I could call
setStartLevel(2, myFavoriteListener) and achieve synchronization?


>
> -> richard
>
>
>>
>>
>>
>>
>>
>>>
>>> -> richard
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> 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
>

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


Re: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by "Richard S. Hall" <he...@ungoverned.org>.
On 12/8/14 20:47 , Benson Margulies wrote:
> On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org> wrote:
>> On 12/8/14 18:07 , Benson Margulies wrote:
>>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>>> useful. Can I call it instead of Framework#start?
>>
>> They don't do the same thing, but certainly you can use either...
>
> That's what I'm trying to sort out. To be perfectly clear about my
> ignorance, I don't understand what the FrameworkStartLevel method is
> for if it's not another way to express the Framework method.
>
> Here's what I have working:
>
> 1. framework.init();
> 2. obtain default bundle start level from FrameworkStartLevel
> 3. installBundle all bundles
> 4. set start level for each bundle by adapting to a BundleStartLevel
> 5. start all bundles
> 6. framework.start
>
> So, where would FrameworkStartLevel#setStartLevel fit into all this?
> Is it only useful if I need to change the start level after
> framework.start()?

Yeah, it is pretty much only useful after you activate the framework 
(i.e., call start()). Although, after a quick look, I'm not 100% certain 
what the Felix framework implementation will do if you call 
setStartLevel() before calling start()...

-> richard

>
>
>
>
>
>>
>> -> richard
>>
>>
>>
>> ---------------------------------------------------------------------
>> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by Benson Margulies <be...@basistech.com>.
On Mon, Dec 8, 2014 at 8:34 PM, Richard S. Hall <he...@ungoverned.org> wrote:
>
> On 12/8/14 18:07 , Benson Margulies wrote:
>>
>> FrameworkStartLevel#setStartLevel takes listeners, which looks really
>> useful. Can I call it instead of Framework#start?
>
>
> They don't do the same thing, but certainly you can use either...


That's what I'm trying to sort out. To be perfectly clear about my
ignorance, I don't understand what the FrameworkStartLevel method is
for if it's not another way to express the Framework method.

Here's what I have working:

1. framework.init();
2. obtain default bundle start level from FrameworkStartLevel
3. installBundle all bundles
4. set start level for each bundle by adapting to a BundleStartLevel
5. start all bundles
6. framework.start

So, where would FrameworkStartLevel#setStartLevel fit into all this?
Is it only useful if I need to change the start level after
framework.start()?





>
>
> -> richard
>
>
>
> ---------------------------------------------------------------------
> 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: Framework#start versus FrameworkStartLevel#setStartLevel

Posted by "Richard S. Hall" <he...@ungoverned.org>.
On 12/8/14 18:07 , Benson Margulies wrote:
> FrameworkStartLevel#setStartLevel takes listeners, which looks really
> useful. Can I call it instead of Framework#start?

They don't do the same thing, but certainly you can use either...

-> richard



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