When compiling servicemix-core in the latest trunk ComponentAssemblyInstallationTest.testComponentInstallation() fails with an NPE being thrown. This test case tests the installation of two jbi installers: logger-component-1.0-jbi-installer.zip and quartz-component-1.0-jbi-installer.zip. During running of this test case a null pointer exception is thrown due to the fact that the descriptor (jbi.xml) doesn't have a bootstrap-class-path element defined.
The question here is should the test component installer jbi.xml files have the bootstrap-class-path element added as an empty element (<bootstrap-class-path/>) ? If this is not favourable one of two things can be done: 1) Add a default value in the Component class (org.apache.servicemix.jbi.deployment) for both the bootstrap and component class paths. That is, private ClassPath bootstrapClassPath; becomes: private ClassPath bootstrapClassPath = new ClassPath(); in Component.java. I'm not sure if there are any related caveats surrounding the use of this kind of default in an XBean mapping class. Anyone who knows please chip in an answer. 2) Put an NPE check in InstallerMBeanImpl.createBootstrap() before the call to buildClassLoader which passes in the bootstrap classpath (line 82) It is worth discussing the best approach with respect to real world deployment of jbi installer zips and implementation of either above option is quite trivial. Let me know if you want an issue raised and a patch submitted for a particular approach. -- View this message in context: http://www.nabble.com/NPE-running-ComponentAssemblyInstallationTest-in-servicemix-core-tf1855321.html#a5066006 Sent from the ServiceMix - Dev forum at Nabble.com.
