System.out.println("\tport: " + port);
System.out.println("\tconnector: " + connectorName);
*/
} catch (Exception e) {
JMException jme
= new JMException("Caught exception when parsing address: "
+ addr);
jme.initCause(e);
throw (jme);
}
/*
System.out.println("host: " + host);
System.out.println("port: " + port);
System.out.println("connectorName: " + connectorName);
*/
try {
pmc = new GenericPortMapperClient(host, port);
/*
* Should add code to check/compare version of client runtime and
* broker here.
*/
} catch (Exception e) {
JMException jme
= new JMException("Caught exception when contacing portmapper.");
jme.initCause(e);
throw (jme);
}
urlString = pmc.getProperty("url", null, "JMX", connectorName);
if (urlString == null) {
JMException jme = new JMException("No JMXServiceURL was found for connector "
+ connectorName + ".\n"
+ "Address used: "
+ addr);
throw (jme);
}
try {
url = new JMXServiceURL(urlString);
} catch (MalformedURLException mfe) {
JMException jme
= new JMException("Caught exception when creating JMXServiceURL.");
jme.initCause(mfe);
throw (jme);
}
return (url);