Class RemoteJMXServer

java.lang.Object
org.apache.uima.aae.jmx.RemoteJMXServer

public class RemoteJMXServer extends Object
  • Constructor Details

    • RemoteJMXServer

      public RemoteJMXServer()
  • Method Details

    • isInitialized

      public boolean isInitialized()
    • initialize

      public void initialize(String jmxDomain, String remoteJMXServerHostname, String remoteJMXServerPort) throws Exception
      Creates a connection to an MBean Server identified by remoteJMXServerHostName and remoteJMXServerPort
      Parameters:
      remoteJMXServerHostName - - MBeanServer host name
      remoteJMXServerPort - - MBeanServer port
      Throws:
      Exception
    • disconnect

      public void disconnect()
      Disconnects from MBeanServer
    • isServerAvailable

      public boolean isServerAvailable()
      Tries to fetch total number of MBeans in the MBeanServer. The real goal here is to check if the server responds. Failure here indicates failed server connection.
      Returns:
    • attachToTempQueue

      public void attachToTempQueue(String tempQueueName) throws Exception
      Throws:
      Exception
    • isClientReplyQueueAvailable

      public boolean isClientReplyQueueAvailable(String queueName)
      Checks if a given queue name exists in remote MBeanServer's registry. NOTE: The code returns true in case the MBeanServer is not available.
      Parameters:
      queueName - - queue to lookup in the MBeanServer
      Returns:
      - true if queue exists, false otherwise
    • normalize

      public String normalize(String destinationName)
      Replaces ':' with '_'. JMX queries containing ':' are illegal.
      Parameters:
      destinationName -
      Returns:
    • main

      public static void main(String[] args)