Thursday Nov 20, 2008

1. Framework Startlevel

The documentation says
org.osgi.framework.startlevel - The initial start level of the framework once it starts execution; the default value is 1.

This means, if you have a bundle installed at a start level that is higher than the framework start level, you won't be able to start it.
Want an example?

felix.auto.install.2= \
     file:bundle/test-bundle.jar

org.osgi.framework.startlevel=1

Now, if you do
"start   <test-bundle-id>"

it is a no-op. After checking your bundle activator again and again, you googled your way here and now you know what happened.

2. Install/Startup ordering

If you have bundles in different levels, like this

felix.auto.start.1= \
     file:bundle/bundle-1.jar
     file:bundle/bundle-2.jar

felix.auto.install.2=\
     file:bundle/bundle-3.jar

and you are betting on the fact that bundle-2 will be stared before bundle-3 is installed, you are in trouble.
Because you see, all bundles are installed first and then bundles in different levels are started up in order.
Comments:

Post a Comment:
  • HTML Syntax: NOT allowed