[jboss-user] [Management, JMX/JBoss] - JBoss App Server Port Number
ronald.turner3@gmail.com
do-not-reply at jboss.com
Thu Oct 25 09:47:53 EDT 2007
Hi,
Iam using JBoss server 4.0.5.
Iam trying to use JMX to internally get the servers port number.
The port number i am looking for is the one configured in the
server.xml file:
<Connector port="8080" ...../>
How would programmatically get this port number?
I can get some port info using the following code:
RMIAdaptor server = (RMIAdaptor)ctx.lookup("jmx/rmi/RMIAdaptor");
ObjectName name = new ObjectName("jboss:readonly=true,service=invoker,target=Naming,type=http");
String invokerString = (String)server.getAttribute(name, "InvokerURLSuffix");
I then parse out the port number.
But this port number is not neccesarily the one in the server.xml file.
Any ideas ?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4098823#4098823
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4098823
More information about the jboss-user
mailing list