http://jira.hyperic.com/browse/HHQ-4515
ActiveMQ plugin - services are not detected when starting agent with no permissions to activemq.
When ActiveMQ is installed by root or activemq user, starting the Hyperic agent as non-root or non-activemq user, the ActiveMQ server is auto-discovered but none of the associated services are auto-discovered.
Starting the Hyperic agent as root or activemq user, the ActiveMQ services are auto-discovered along with the ActiveMQ server.
Expected Result:
Services are auto-discovered when Server is auto-discovered
Actual Result:
Starting the Hyperic agent with non-root or non-activemq user does not auto-discover services but auto-discovers services
Steps to Reproduce:
1. Install Hyperic agent on platform running ActiveMQ
2. Start agent as non-root or non-activemq user
3. Log into Hyperic.
4. Add ActiveMQ platform in to inventory from auto-discovery
5. Allow time for services and availability/metrics to collect
6. Select ActiveMQ platform -> ActiveMQ server
7. Note no services are auto-discovered
Additional Information:
This is also visible when executing the ActiveMQA command line discover operation:
$ java -jar hq-pdk-4.5.1.BUILD-SNAPSHOT.jar -Dplugins.include=activemq -m discover
1 servers detected
Server: vmc-ssrc-rh133.eng.vmware.com ActiveMQ 5.4 [/opt/activemq/apache-activemq-5.4.2]
AIID...../opt/activemq/apache-activemq-5.4.2
config...
product..process.query=State.Name.sw=java,Args.*.eq=-Dactivemq.home=/opt/activemq/apache-activemq-5.4.2,
metric...
control..null
ERROR [main] [PluginDiscoverer] ActiveMQ 5.4 Linux-->org.hyperic.hq.product.PluginException: jmx.url==null
org.hyperic.hq.product.PluginException: jmx.url==null
at org.hyperic.hq.product.jmx.MxServerDetector.discoverServices(MxServerDetector.java:477)
at org.hyperic.hq.product.ServerDetector.discoverResources(ServerDetector.java:219)
at org.hyperic.hq.product.util.PluginDiscoverer.runtimeScan(PluginDiscoverer.java:604)
at org.hyperic.hq.product.util.PluginDiscoverer.start(PluginDiscoverer.java:321)
at org.hyperic.hq.product.util.PluginDumper.testDiscovery(PluginDumper.java:1151)
at org.hyperic.hq.product.util.PluginDumper.invoke(PluginDumper.java:456)
at org.hyperic.hq.product.util.PluginMain.main(PluginMain.java:321)
Caused by: java.net.MalformedURLException: jmx.url==null
at org.hyperic.hq.product.jmx.MxUtil.getMBeanConnector(MxUtil.java:435)
at org.hyperic.hq.product.jmx.MxServerDetector.discoverServices(MxServerDetector.java:474)
... 6 more
Anonymous