I'm also interested in this.

I've tried two way to configure the start level:
1. In the config.properties, set felix.auto.start and felix.auto.install
    This seems to work, but I have to use fixed bundle name and hard to
maintain.
2. Use FileInstall to make sure your project bundle goes after the platform
bundle.
    It only gives me a simple way to do two level configuration.

Also looking for the best practice.

Regards
LongkerDandy

On Fri, Oct 15, 2010 at 7:16 AM, Larry Touve <[email protected]>wrote:

> I've been trying to figure out how to manage the startup of our application
> bundles (~25).  There are some dependencies between bundles and we can get
> them running by deploying them (using asadmin -type=osgi) in the order we
> want.  Everything runs fine, except when we restart the framework (we're
> using Glassfish 3.0.1 which has Felix 2.0.2).  It doesn't seem to happen all
> the time, but occasionally we get severe startup errors.
>
>  I attempted to install a startup manager, by using the StartLevel service
> and a BundleListener.  When one of my bundles was installed, I would set the
> startlevel.  That appeared to work on the initial deployment.  When the
> bundles were examined through the Felix Web Console, they showed the correct
> Start Level (3).  However, when the framework was restarted, the bundles
> reverted to the default Start Level (1).   It seemed that either they were
> started up prior to my Manager (which was at Start Level 1), or they weren't
> triggering an INSTALL event, just a STARTUP event, since they were already
> deployed.  I noticed that one of the bundles that I started by dropping in
> the autostart/bundles directory did retain the Start Level, since that is
> recorded in the bundle's cache directory, but it looks like the bundles that
> are started via 'asadmin deploy' behave differently.
>
>  Has anyone had any luck developing their own Startup Manager?
>
> Thanks,
>  Larry
>
>

Reply via email to