Package com.adaptris.jmx.remote.jms
Class JmsJmxConnectorServer
- java.lang.Object
-
- javax.management.NotificationBroadcasterSupport
-
- javax.management.remote.JMXConnectorServer
-
- com.adaptris.jmx.remote.jms.JmsJmxConnectorServer
-
- All Implemented Interfaces:
javax.management.MBeanRegistration,javax.management.NotificationBroadcaster,javax.management.NotificationEmitter,javax.management.remote.JMXAddressable,javax.management.remote.JMXConnectorServerMBean
public class JmsJmxConnectorServer extends javax.management.remote.JMXConnectorServerImplementation ofJMXConnectorServerthat provides JMX connectivity via JMS.As this implementation uses a JMS Provider to provide connectivity, clients aren't directly connected to this server; requests automatically appear on the given
Destinationthat this is registered against. As a result, you will find that the standardJMXConnectorServer.getConnectionIds()may return you an empty array as the correspondingJMXConnectorServer.connectionClosed(String, String, Object),JMXConnectorServer.connectionOpened(String, String, Object),JMXConnectorServer.connectionFailed(String, String, Object)methods are never called.
-
-
Constructor Summary
Constructors Constructor Description JmsJmxConnectorServer(javax.management.remote.JMXServiceURL url, java.util.Map environment, javax.management.MBeanServer server, JmsJmxConnectionFactory factory)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddNotificationListener(javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback)javax.management.remote.JMXServiceURLgetAddress()java.util.MapgetAttributes()booleanisActive()voidremoveNotificationListener(javax.management.NotificationListener listener)voidremoveNotificationListener(javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback)voidsendNotification(javax.management.Notification notification)voidstart()voidstop()javax.management.remote.JMXConnectortoJMXConnector(java.util.Map<java.lang.String,?> env)
-
-
-
Constructor Detail
-
JmsJmxConnectorServer
public JmsJmxConnectorServer(javax.management.remote.JMXServiceURL url, java.util.Map environment, javax.management.MBeanServer server, JmsJmxConnectionFactory factory) throws java.io.IOExceptionConstructor.- Parameters:
url- the JMXServiceURL.environment- the initial environment forgetAttributes()server- theMBeanServerthat we should be attached to.factory- theJmsJmxConnectionFactorythat will used to connection to the JMS Provider.- Throws:
java.io.IOException- wrapping any other exception.
-
-
Method Detail
-
start
public void start() throws java.io.IOException- Throws:
java.io.IOException
-
stop
public void stop() throws java.io.IOException- Throws:
java.io.IOException
-
toJMXConnector
public javax.management.remote.JMXConnector toJMXConnector(java.util.Map<java.lang.String,?> env) throws java.io.IOExceptionNote that this will throw an UnsupportedOperationException
- Specified by:
toJMXConnectorin interfacejavax.management.remote.JMXConnectorServerMBean- Overrides:
toJMXConnectorin classjavax.management.remote.JMXConnectorServer- Throws:
java.io.IOException
-
isActive
public boolean isActive()
-
getAddress
public javax.management.remote.JMXServiceURL getAddress()
-
getAttributes
public java.util.Map getAttributes()
-
sendNotification
public void sendNotification(javax.management.Notification notification)
- Overrides:
sendNotificationin classjavax.management.NotificationBroadcasterSupport
-
addNotificationListener
public void addNotificationListener(javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws java.lang.IllegalArgumentException- Specified by:
addNotificationListenerin interfacejavax.management.NotificationBroadcaster- Overrides:
addNotificationListenerin classjavax.management.NotificationBroadcasterSupport- Throws:
java.lang.IllegalArgumentException
-
removeNotificationListener
public void removeNotificationListener(javax.management.NotificationListener listener) throws javax.management.ListenerNotFoundException- Specified by:
removeNotificationListenerin interfacejavax.management.NotificationBroadcaster- Overrides:
removeNotificationListenerin classjavax.management.NotificationBroadcasterSupport- Throws:
javax.management.ListenerNotFoundException
-
removeNotificationListener
public void removeNotificationListener(javax.management.NotificationListener listener, javax.management.NotificationFilter filter, java.lang.Object handback) throws javax.management.ListenerNotFoundException- Specified by:
removeNotificationListenerin interfacejavax.management.NotificationEmitter- Overrides:
removeNotificationListenerin classjavax.management.NotificationBroadcasterSupport- Throws:
javax.management.ListenerNotFoundException
-
-