Log service has the same issues with possibly missing events since a log
service implementation is not required to cache log entries indefinitely.
The only reliable way to record all events is to get a bundle tracker
registered as soon as possible.  As Peter mentions the earliest and most
reliable way to do that is by using a custom launcher that can register the
bundle tracker/listener from the very start before the framework is
started.

Tom





From:   Peter Kriens <[email protected]>
To:     OSGi Developer Mail List <[email protected]>,
Date:   04/25/2013 05:40 AM
Subject:        Re: [osgi-dev] recording bundle start/shutdown
Sent by:        [email protected]



If you launch the framework yourself with the launcher API then you can
register the bundle listener before the framework is started using the
Framework's context.

Notice that all events are also in the log service ...

Kind regards,

                 Peter Kriens



On 23 apr. 2013, at 20:52, Scott Lewis wrote:

> What would be the simplest way to record the bundle state changes
(installed->resolved->starting->etc) at framework startup and shutdown?
What I'm wanting to do is to take an existing OSGi application...and
understand the startup and shutdown sequence...e.g. when/what thread
[stack?] is responsible for each state transition.
>
> I suppose it could be a BundleTracker...but I wanted to know if there
were other mechanisms.
>
> Thanksinadvance,
>
> Scott
>
>
>
>
> _______________________________________________
> OSGi Developer Mail List
> [email protected]
> https://mail.osgi.org/mailman/listinfo/osgi-dev

_______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev

<<inline: graycol.gif>>

_______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to