org.qi4j.library.circuitbreaker.jmx
Class CircuitBreakerJMX

java.lang.Object
  extended by javax.management.NotificationBroadcasterSupport
      extended by org.qi4j.library.circuitbreaker.jmx.CircuitBreakerJMX
All Implemented Interfaces:
javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, CircuitBreakerJMXMBean

public class CircuitBreakerJMX
extends javax.management.NotificationBroadcasterSupport
implements CircuitBreakerJMXMBean

MBean for circuit breakers. Exposes CB properties and also the property changes as notifications.


Constructor Summary
CircuitBreakerJMX(CircuitBreaker circuitBreaker, javax.management.ObjectName mbeanObjectName)
           
 
Method Summary
 java.lang.String getEnableOn()
           
 java.lang.String getLastErrorMessage()
           
 double getServiceLevel()
           
 java.lang.String getStatus()
           
 int getThreshold()
           
 java.lang.String getTrippedOn()
           
 void trip()
           
 java.lang.String turnOn()
           
 
Methods inherited from class javax.management.NotificationBroadcasterSupport
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CircuitBreakerJMX

public CircuitBreakerJMX(CircuitBreaker circuitBreaker,
                         javax.management.ObjectName mbeanObjectName)
Method Detail

getStatus

public java.lang.String getStatus()
Specified by:
getStatus in interface CircuitBreakerJMXMBean

getThreshold

public int getThreshold()
Specified by:
getThreshold in interface CircuitBreakerJMXMBean

getServiceLevel

public double getServiceLevel()
Specified by:
getServiceLevel in interface CircuitBreakerJMXMBean

getLastErrorMessage

public java.lang.String getLastErrorMessage()
Specified by:
getLastErrorMessage in interface CircuitBreakerJMXMBean

getTrippedOn

public java.lang.String getTrippedOn()
Specified by:
getTrippedOn in interface CircuitBreakerJMXMBean

getEnableOn

public java.lang.String getEnableOn()
Specified by:
getEnableOn in interface CircuitBreakerJMXMBean

turnOn

public java.lang.String turnOn()
Specified by:
turnOn in interface CircuitBreakerJMXMBean

trip

public void trip()
Specified by:
trip in interface CircuitBreakerJMXMBean