Examples of KernelDelegate


Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

        ClassLoader oldcl = Thread.currentThread().getContextClassLoader();
        try {
            Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
            JMXConnector jmxConnector = JMXConnectorFactory.connect(address, environment);
            mbServerConnection = jmxConnector.getMBeanServerConnection();
            kernel = new KernelDelegate(mbServerConnection);
            kernel.shutdown();

        } finally {
            Thread.currentThread().setContextClassLoader(oldcl);
        }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

            Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
            for (int tries = maxTries; true; tries--) {
                try {
                    JMXConnector jmxConnector = JMXConnectorFactory.connect(address, environment);
                    mbServerConnection = jmxConnector.getMBeanServerConnection();
                    kernel = new KernelDelegate(mbServerConnection);
                    break;
                } catch (Exception e) {
                    if (tries == 0) {
                        throw new Exception("Could not connect");
                    }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

    private CommandContext commandContext;

    public JMXDeploymentManager(JMXConnector jmxConnector) throws IOException {
        this.jmxConnector = jmxConnector;
        mbServerConnection = jmxConnector.getMBeanServerConnection();
        kernel = new KernelDelegate(mbServerConnection);
        configurationManager = ConfigurationUtil.getConfigurationManager(kernel);
        commandContext = new CommandContext();
        commandContext.setLogErrors(true);
        commandContext.setVerbose(true);
    }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

              + "/JMXConnector");
      JMXConnector jmxConnector = JMXConnectorFactory.connect(address,
          map);
      MBeanServerConnection mbServerConnection = jmxConnector
          .getMBeanServerConnection();
      kernel = new KernelDelegate(mbServerConnection);

    } catch (MalformedURLException e) {
      e.printStackTrace();
    }
    return kernel;
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

    private boolean isSameMachine;

    public RemoteDeploymentManager(JMXConnector jmxConnector, String hostname) throws IOException {
        this.jmxConnector = jmxConnector;
        MBeanServerConnection mbServerConnection = jmxConnector.getMBeanServerConnection();
        initialize(new KernelDelegate(mbServerConnection));
        checkSameMachine(hostname);
    }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

            Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
            for (int tries = maxTries; true; tries--) {
                try {
                    JMXConnector jmxConnector = JMXConnectorFactory.connect(address, environment);
                    mbServerConnection = jmxConnector.getMBeanServerConnection();
                    kernel = new KernelDelegate(mbServerConnection);
                    break;
                } catch (Exception e) {
                    if (tries == 0) {
                        throw new Exception("Could not connect");
                    }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

        ClassLoader oldcl = Thread.currentThread().getContextClassLoader();
        try {
            Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
            JMXConnector jmxConnector = JMXConnectorFactory.connect(address, environment);
            mbServerConnection = jmxConnector.getMBeanServerConnection();
            kernel = new KernelDelegate(mbServerConnection);
            kernel.shutdown();

        } finally {
            Thread.currentThread().setContextClassLoader(oldcl);
        }
View Full Code Here

Examples of org.apache.geronimo.kernel.jmx.KernelDelegate

    private CommandContext commandContext;

    public JMXDeploymentManager(JMXConnector jmxConnector) throws IOException {
        this.jmxConnector = jmxConnector;
        mbServerConnection = jmxConnector.getMBeanServerConnection();
        kernel = new KernelDelegate(mbServerConnection);
        configurationManager = ConfigurationUtil.getConfigurationManager(kernel);
        commandContext = new CommandContext();
        commandContext.setLogErrors(true);
        commandContext.setVerbose(true);
    }
View Full Code Here

Examples of org.apache.geronimo.system.jmx.KernelDelegate

    try {
      JMXServiceURL address = new JMXServiceURL(
          "service:jmx:rmi:///jndi/rmi://localhost" + ":" + port + "/JMXConnector");
      JMXConnector jmxConnector = JMXConnectorFactory.connect(address, map);
      MBeanServerConnection mbServerConnection = jmxConnector.getMBeanServerConnection();
      kernel = new KernelDelegate(mbServerConnection);
    } catch (MalformedURLException e) {
      e.printStackTrace();
    }
    return kernel;
  }
View Full Code Here

Examples of org.apache.geronimo.system.jmx.KernelDelegate

    }

    public void init(JMXConnector jmxConnector, String hostname) throws IOException {
        this.jmxConnector = jmxConnector;
        MBeanServerConnection mbServerConnection = jmxConnector.getMBeanServerConnection();
        initialize(new KernelDelegate(mbServerConnection));
        checkSameMachine(hostname);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.