Package org.apache.activemq.web
Class RemoteJMXBrokerFacade
java.lang.Object
org.apache.activemq.web.BrokerFacadeSupport
org.apache.activemq.web.RemoteJMXBrokerFacade
- All Implemented Interfaces:
BrokerFacade
A
BrokerFacade which uses a JMX-Connection to communicate with a
broker-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected JMXConnectorprotected Set<ObjectName>findBrokers(MBeanServerConnection connection) Finds all ActiveMQ-Brokers registered on a certain JMX-Server or, if a JMX-BrokerName has been set, the broker with that name.org.apache.activemq.broker.jmx.BrokerViewMBeanAdmin view of the broker.The name of the active broker (f.e.protected <T> Collection<T>getManagedObjects(ObjectName[] names, Class<T> type) org.apache.activemq.broker.jmx.ManagementContextprotected MBeanServerConnectionprotected booleanisConnectionActive(JMXConnector connector) newProxyInstance(ObjectName objectName, Class interfaceClass, boolean notificationBroadcaster) voidpurgeQueue(org.apache.activemq.command.ActiveMQDestination destination) Purges the given destinationqueryNames(ObjectName name, QueryExp query) voidsetBrokerName(String brokerName) voidsetConfiguration(WebConsoleConfiguration configuration) voidshutdown()Shutdown this facade aka close any open connection.Methods inherited from class org.apache.activemq.web.BrokerFacadeSupport
getConnection, getConnections, getConnections, getConnector, getConnectors, getConsumersOnConnection, getDestinationByName, getDurableTopicSubscribers, getInactiveDurableTopicSubscribers, getJobScheduler, getNetworkBridges, getNetworkConnectors, getNonDurableTopicSubscribers, getQueue, getQueueConsumers, getQueueProducers, getQueues, getScheduledJobs, getTopic, getTopicProducers, getTopics, getTopicSubscribers, isJobSchedulerStarted
-
Constructor Details
-
RemoteJMXBrokerFacade
public RemoteJMXBrokerFacade()
-
-
Method Details
-
setBrokerName
-
getConfiguration
-
setConfiguration
-
shutdown
public void shutdown()Shutdown this facade aka close any open connection. -
getBrokerAdmin
Description copied from interface:BrokerFacadeAdmin view of the broker.- Returns:
- not
null - Throws:
Exception
-
getBrokerName
Description copied from interface:BrokerFacadeThe name of the active broker (f.e. 'localhost' or 'my broker').- Returns:
- not
null - Throws:
ExceptionMalformedObjectNameException
-
getMBeanServerConnection
- Throws:
Exception
-
isConnectionActive
-
createConnection
-
closeConnection
protected void closeConnection() -
findBrokers
protected Set<ObjectName> findBrokers(MBeanServerConnection connection) throws IOException, MalformedObjectNameException Finds all ActiveMQ-Brokers registered on a certain JMX-Server or, if a JMX-BrokerName has been set, the broker with that name.- Parameters:
connection- notnull- Returns:
- Set with ObjectName-elements
- Throws:
IOExceptionMalformedObjectNameException
-
purgeQueue
public void purgeQueue(org.apache.activemq.command.ActiveMQDestination destination) throws Exception Description copied from interface:BrokerFacadePurges the given destination- Throws:
Exception
-
getManagementContext
public org.apache.activemq.broker.jmx.ManagementContext getManagementContext()- Specified by:
getManagementContextin classBrokerFacadeSupport
-
getManagedObjects
- Overrides:
getManagedObjectsin classBrokerFacadeSupport
-
queryNames
- Specified by:
queryNamesin classBrokerFacadeSupport- Throws:
Exception
-
newProxyInstance
public Object newProxyInstance(ObjectName objectName, Class interfaceClass, boolean notificationBroadcaster) throws Exception - Specified by:
newProxyInstancein classBrokerFacadeSupport- Throws:
Exception
-