From 9d0c6edab10103c67aa9a4a11c5bc2f57ab0902a Mon Sep 17 00:00:00 2001 From: Alexandre Moutot Date: Wed, 9 Oct 2013 15:47:48 +0200 Subject: [PATCH] Add a JMXProvider Class Loader to be able to load Provider using getConnectorAsService from JMXConnectorFactory. The protocol remoting-jmx using by JBOSS > 7 need that to work. --- bindings/java/org/collectd/java/GenericJMXConfConnection.java | 1 + 1 file changed, 1 insertion(+) diff --git a/bindings/java/org/collectd/java/GenericJMXConfConnection.java b/bindings/java/org/collectd/java/GenericJMXConfConnection.java index 7fad08f9..99b140a2 100644 --- a/bindings/java/org/collectd/java/GenericJMXConfConnection.java +++ b/bindings/java/org/collectd/java/GenericJMXConfConnection.java @@ -118,6 +118,7 @@ private void connect () /* {{{ */ environment = new HashMap (); environment.put (JMXConnector.CREDENTIALS, credentials); + environment.put(JMXConnectorFactory.PROTOCOL_PROVIDER_CLASS_LOADER, this.getClass().getClassLoader()); } try -- 2.30.2