Search in sources :

Example 26 with ManagementException

use of org.apache.geode.management.ManagementException in project geode by apache.

the class SystemManagementService method init.

/**
   * This method will initialize all the internal components for Management and Monitoring
   * 
   * It will a)start an JMX connectorServer b) create a notification hub c)register the
   * ManagementFunction
   */
private SystemManagementService init() {
    try {
        this.localManager = new LocalManager(repo, system, this, cache);
        this.localManager.startManager();
        this.listener = new ManagementMembershipListener(this);
        system.getDistributionManager().addMembershipListener(listener);
        isStarted = true;
        return this;
    } catch (CancelException e) {
        // Rethrow all CancelExceptions (fix for defect 46339)
        throw e;
    } catch (Exception e) {
        // Wrap all other exceptions as ManagementExceptions
        logger.error(e.getMessage(), e);
        throw new ManagementException(e);
    }
}
Also used : ManagementException(org.apache.geode.management.ManagementException) CancelException(org.apache.geode.CancelException) AlreadyRunningException(org.apache.geode.management.AlreadyRunningException) DistributedSystemDisconnectedException(org.apache.geode.distributed.DistributedSystemDisconnectedException) CancelException(org.apache.geode.CancelException) ManagementException(org.apache.geode.management.ManagementException)

Aggregations

ManagementException (org.apache.geode.management.ManagementException)26 IOException (java.io.IOException)8 ObjectName (javax.management.ObjectName)8 InstanceNotFoundException (javax.management.InstanceNotFoundException)6 MalformedObjectNameException (javax.management.MalformedObjectNameException)5 Notification (javax.management.Notification)4 InternalCache (org.apache.geode.internal.cache.InternalCache)4 IntrospectionException (java.beans.IntrospectionException)3 Type (java.lang.reflect.Type)3 CancellationException (java.util.concurrent.CancellationException)3 ExecutionException (java.util.concurrent.ExecutionException)3 RejectedExecutionException (java.util.concurrent.RejectedExecutionException)3 InstanceAlreadyExistsException (javax.management.InstanceAlreadyExistsException)3 MBeanRegistrationException (javax.management.MBeanRegistrationException)3 NotCompliantMBeanException (javax.management.NotCompliantMBeanException)3 ObjectInstance (javax.management.ObjectInstance)3 RegionExistsException (org.apache.geode.cache.RegionExistsException)3 TimeoutException (org.apache.geode.cache.TimeoutException)3 DistributedMember (org.apache.geode.distributed.DistributedMember)3 BytesToString (org.apache.geode.management.internal.cli.util.BytesToString)3