Two Laptop Bag*
The moose likes EJB and other Java EE Technologies and the fly likes Weblogic Mbean over JMX Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Weblogic Mbean over JMX" Watch "Weblogic Mbean over JMX" New topic
Author

Weblogic Mbean over JMX

Ranadhir Nag
Ranch Hand

Joined: Mar 09, 2006
Posts: 138
We connect to a weblogic server MBean over JMX as follows:


String protocol = "t3";
Integer portInteger = Integer.valueOf(portString);
int port = portInteger.intValue();
String jndiroot = "/jndi/";
String mserver = "weblogic.management.mbeanservers.runtime";
JMXServiceURL serviceURL = new JMXServiceURL(protocol, hostname, port, jndiroot + mserver);
Hashtable h = new Hashtable();

h.put(Context.SECURITY_PRINCIPAL, username);
h.put(Context.SECURITY_CREDENTIALS, password);
h.put(JMXConnectorFactory.PROTOCOL_PROVIDER_PACKAGES, "weblogic.management.remote");
h.put("jmx.remote.x.request.waiting.timeout", new Long(10000));

connector = JMXConnectorFactory.connect(serviceURL, h);
connection = connector.getMBeanServerConnection();

What we are confused is the port to which we should address the reqeust - the server listen port or the administration port(NOTE : not the admin server port).
We seem to be getting the details like server Name and adminportenabled attributes by listenin to the server listen port itself.

In that case,what is the administration port used for - when should we address requests to it.
I also see a note that the adminitration port is always SSL-enabled ;can be made to listen to a 't3' protocol?

 
Consider Paul's rocket mass heater.
 
subject: Weblogic Mbean over JMX