Package mx4j.tools.remote

Examples of mx4j.tools.remote.ConnectionManager


      JMXServiceURL address = getAddress();
      String protocol = address.getProtocol();
      ConnectionResolver resolver = ConnectionResolver.newConnectionResolver(protocol, environment);
      if (resolver == null) throw new MalformedURLException("Unsupported protocol: " + protocol);

      ConnectionManager server = (ConnectionManager)resolver.lookupClient(address, environment);
      server = (ConnectionManager)resolver.bindClient(server, environment);

      Object credentials = environment == null ? null : environment.get(CREDENTIALS);
      connection = server.connect(credentials);
   }
View Full Code Here


   static ConnectionManager find(JMXServiceURL address)
   {
      synchronized (HTTPConnectorServer.class)
      {
         ConnectionManager manager = (ConnectionManager)instances.get(address);
         if (manager != null) return manager;

         Logger logger = Log.getLogger(HTTPConnectorServer.class.getName());
         if (logger.isEnabledFor(Logger.DEBUG)) logger.debug("Known HTTPConnectorServers bound at " + instances.keySet());
         return null;
View Full Code Here

   public String connect(Object credentials) throws IOException, SecurityException
   {
      JMXServiceURL address = findJMXServiceURL();

      // Lookup the ConnectionManager
      ConnectionManager connectionManager = HTTPConnectorServer.find(address);
      if (connectionManager == null) throw new IOException("Could not find ConnectionManager. Make sure a HTTPConnectorServer is in classloader scope and bound at this address " + address);

      Connection connection = connectionManager.connect(credentials);
      addConnection(connection);
      return connection.getConnectionId();
   }
View Full Code Here

TOP

Related Classes of mx4j.tools.remote.ConnectionManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.