Tried deploying a bundle and got an NPE. One of the config properties was set to an empty string - I'm wondering if this is now represented as a null??? 2011-10-24 12:13:05,431 ERROR [ResourceContainer.invoker.nonDaemon-1] (org.rhq.plugins.ant.AntBundlePluginComponent)- Failed to deploy bundle [class org.rhq.core.pluginapi.bundle.BundleDeployRequest: deployment=[BundleResourceDeployment: bdd=[BundleDeployment[id=10001, name=Deployment [1] of Version [2.0] to [test-destination]]], resource=[Resource[id=10001, type=Linux, key=mazztower, name=mazztower, parent=<null>, version=Linux 2.6.38.6-26.rc1.fc15.x86_64]]], full-deploy-directory=[/tmp/deleteme/example1], clean=[false], revert=[false]] java.lang.Exception: Failed to execute the bundle Ant script at org.rhq.plugins.ant.AntBundlePluginComponent.deployBundle(AntBundlePluginComponent.java:157) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.rhq.core.pc.inventory.ResourceContainer$ComponentInvocationThread.call(ResourceContainer.java:552) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at java.util.Hashtable.put(Hashtable.java:394) at java.util.Properties.setProperty(Properties.java:143) at org.rhq.plugins.ant.AntBundlePluginComponent.createAntProperties(AntBundlePluginComponent.java:340) at org.rhq.plugins.ant.AntBundlePluginComponent.deployBundle(AntBundlePluginComponent.java:119) ... 10 more
Change to AntBundlePluginComponent: - antProps.setProperty(name, value); + if (value != null) { + antProps.setProperty(name, value); + } I will commit this on next push to master.
FWIW, to test/replicate this, I used the procedures in Bug #738584 - I think this specifically was caused by setting the jmx-admin-password property to an empty string (which I believe forces a check of "unset") but I don't know for sure if that was the cause.
git commit 20c8c79
regression tested basic bundle deploy.
changing status of VERIFIED BZs for JON 2.4.2 and JON 3.0 to CLOSED/CURRENTRELEASE