Package org.jgroups.jmx
Class JmxConfigurator
java.lang.Object
org.jgroups.jmx.JmxConfigurator
- Version:
- $Id: JmxConfigurator.java,v 1.10 2006/08/09 13:02:21 belaban Exp $
- Author:
- Bela Ban
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static Protocol
findProtocol
(Protocol prot) static JChannel
registerChannel
(JChannel channel, MBeanServer server, String name) Registers an already created channel with the MBeanServer.static JChannel
registerChannel
(JChannel channel, MBeanServer server, String domain, String cluster_name, boolean register_protocols) Registers an already created channel with the MBeanServer.static JChannelFactory
registerChannelFactory
(JChannelFactory factory, MBeanServer server, String name) static void
registerProtocols
(MBeanServer server, JChannel channel, String prefix) Takes all protocols of an existing stack, creates corresponding MBean proxies and registers them with the MBean serverstatic void
unregister
(MBeanServer server, String object_name) Unregisters object_name and everything under itstatic void
unregisterChannel
(MBeanServer server, String name) static void
unregisterChannel
(MBeanServer server, ObjectName name) static void
unregisterProtocols
(MBeanServer server, JChannel channel, String channel_name)
-
Constructor Details
-
JmxConfigurator
public JmxConfigurator()
-
-
Method Details
-
registerChannel
public static JChannel registerChannel(JChannel channel, MBeanServer server, String domain, String cluster_name, boolean register_protocols) throws Exception Registers an already created channel with the MBeanServer. Creates an org.jgroups.jmx.JChannel which delegates to the org.jgroups.JChannel and registers it. Optionally, this method will also try to create one MBean proxy for each protocol in the channel's protocol stack, and register it as well.- Parameters:
channel
-server
-domain
- Has to be a JMX ObjectName of the domain, e.g. DefaultDomain:name=JGroupsregister_protocols
-- Returns:
- org.jgroups.jmx.JChannel for the specified org.jgroups.JChannel
- Throws:
Exception
-
registerChannel
public static JChannel registerChannel(JChannel channel, MBeanServer server, String name) throws Exception Registers an already created channel with the MBeanServer. Creates an org.jgroups.jmx.JChannel which delegates to the org.jgroups.JChannel and registers it.- Parameters:
channel
-server
-name
- The JMX ObjectName- Returns:
- org.jgroups.jmx.JChannel for the specified org.jgroups.JChannel
- Throws:
Exception
-
unregisterChannel
- Throws:
Exception
-
unregisterChannel
- Throws:
Exception
-
registerChannelFactory
public static JChannelFactory registerChannelFactory(JChannelFactory factory, MBeanServer server, String name) throws Exception - Throws:
Exception
-
registerProtocols
public static void registerProtocols(MBeanServer server, JChannel channel, String prefix) throws Exception Takes all protocols of an existing stack, creates corresponding MBean proxies and registers them with the MBean server- Parameters:
channel
-prefix
-- Throws:
Exception
-
unregisterProtocols
-
unregister
Unregisters object_name and everything under it- Parameters:
object_name
-- Throws:
Exception
-
findProtocol
protected static Protocol findProtocol(Protocol prot) throws ClassNotFoundException, IllegalAccessException, InstantiationException
-