Class ConnectorServer

All Implemented Interfaces:
LifeCycle

public class ConnectorServer extends AbstractLifeCycle

LifeCycle wrapper for JMXConnectorServer.

This class provides the following facilities:

  • participates in the Server lifecycle
  • starts the RMI registry if not there already
  • allows to bind the RMI registry and the RMI server to the loopback interface
  • makes it easy to use TLS for the JMX communication
  • Field Details

    • RMI_REGISTRY_CLIENT_SOCKET_FACTORY_ATTRIBUTE

      public static final String RMI_REGISTRY_CLIENT_SOCKET_FACTORY_ATTRIBUTE
      See Also:
    • LOG

      private static final Logger LOG
    • _jmxURL

      private JMXServiceURL _jmxURL
    • _environment

      private final Map<String,Object> _environment
    • _objectName

      private final String _objectName
    • _sslContextFactory

      private final SslContextFactory _sslContextFactory
    • _registryPort

      private int _registryPort
    • _rmiPort

      private int _rmiPort
    • _connectorServer

      private JMXConnectorServer _connectorServer
    • _registry

      private Registry _registry
  • Constructor Details

    • ConnectorServer

      public ConnectorServer(JMXServiceURL serviceURL, String name)
      Constructs a ConnectorServer
      Parameters:
      serviceURL - the address of the new ConnectorServer
      name - object name string to be assigned to ConnectorServer bean
    • ConnectorServer

      public ConnectorServer(JMXServiceURL svcUrl, Map<String,?> environment, String name)
      Constructs a ConnectorServer
      Parameters:
      svcUrl - the address of the new ConnectorServer
      environment - a set of attributes to control the new ConnectorServer's behavior. This parameter can be null. Keys in this map must be Strings. The appropriate type of each associated value depends on the attribute. The contents of environment are not changed by this call.
      name - object name string to be assigned to ConnectorServer bean
    • ConnectorServer

      public ConnectorServer(JMXServiceURL svcUrl, Map<String,?> environment, String name, SslContextFactory sslContextFactory)
  • Method Details