Given a bundle A that optionally resolves packages from Bundle B, what is the best way to install Bundle B so that Bundle A's dependencies are satisfied? For example...
Bundle org.springframework.aop-3.0.0.CI-395.jar imports package net.sf.cglib.core, with a "resolution:=optional" directive. On a clean start of dm Server 2.0.0.M5, this import is not resolved. (Go to Admin > OSGi State, and select the org.springframework.aop bundle. The provider for net.sf.cglib.core is blank.)
I tried adding com.springsource.net.sf.cglib-2.1.3.jar to SERVER_HOME/repository/usr, and then to SERVER_HOME/repository/ext, but still the optional resolution did not take place. I restarted the server and refreshed the org.springframework.aop bundle after each of these attempts.
When I add "file:repository/usr/com.springsource.net.sf.cglib-2.1.3.jar" to com.springsource.kernel.region.bundles in com.springsource.kernel.launch.properties, then the import resolved as expected, and the aop package had access to cglib.
Is it necessary to add all "optional" bundles to com.springsource.kernel.launch.properties? Based on the user's guide (http://static.springsource.org/s2-dm...l/ch04s03.html), I thought that putting them in SERVER_HOME/repository/usr or SERVER_HOME/repository/ext was sufficient.