I need to determine the servers (2.4.x) domain name at runtime.
Is there a class that I can use which delivers the domain name the server was started with? Or is there some other environmental information which I can use?
Is there anyone out there to help me out?
Since this is the JMX forum, you can get the
MBean Server's default domain using the
However, I think you mean the domain name of the server.
InetAddress local = InetAddress.getLocalHost();
Then you have two options
The second method is potentially blocking because
it can access a dns.