1 package org.jgroups.jmx; 2 3 import org.jgroups.*; 4 import org.w3c.dom.Element ; 5 6 import java.io.Serializable ; 7 import java.util.Map ; 8 9 13 public interface JChannelMBean { 14 void create() throws Exception ; 15 void start() throws Exception ; 16 void stop(); 17 void destroy(); 18 19 org.jgroups.JChannel getChannel(); 21 22 String getProperties(); 23 void setProperties(String props); 24 25 String getVersion(); 26 27 String getObjectName(); 28 void setObjectName(String name); 29 30 int getNumberOfTasksInTimer(); 31 String dumpTimerQueue(); 32 int getTimerThreads(); 33 34 35 void setClusterConfig(Element el); 36 37 String getGroupName(); 38 void setGroupName(String group_name); 39 40 String getClusterName(); 41 void setClusterName(String cluster_name); 42 43 boolean getReceiveBlockEvents(); 44 void setReceiveBlockEvents(boolean flag); 45 46 boolean getReceiveLocalMessages(); 47 void setReceiveLocalMessages(boolean flag); 48 49 boolean getAutoReconnect(); 50 void setAutoReconnect(boolean flag); 51 52 boolean getAutoGetState(); 53 void setAutoGetState(boolean flag); 54 55 Map dumpStats(); 56 57 View getView(); 58 String getViewAsString(); 59 Address getLocalAddress(); 60 String getLocalAddressAsString(); 61 void setChannelListener(ChannelListener channel_listener); 62 boolean getStatsEnabled(); 63 void setStatsEnabled(boolean flag); 64 void resetStats(); 65 long getSentMessages(); 66 long getSentBytes(); 67 long getReceivedMessages(); 68 long getReceivedBytes(); 69 70 boolean isOpen(); 71 72 boolean isConnected(); 73 74 int getNumMessages(); 75 76 String dumpQueue(); 77 78 String printProtocolSpec(boolean include_properties); 79 80 String toString(boolean print_details); 81 82 void connect(String channel_name) throws ChannelException, ChannelClosedException; 83 84 void disconnect(); 85 86 void close(); 87 88 void shutdown(); 89 90 void send(Message msg) throws ChannelNotConnectedException, ChannelClosedException; 91 92 void send(Address dst, Address src, Serializable obj) throws ChannelNotConnectedException, ChannelClosedException; 93 94 void sendToAll(String msg) throws ChannelNotConnectedException, ChannelClosedException; 95 96 98 void down(Event evt); 99 100 Object receive(long timeout) throws ChannelNotConnectedException, ChannelClosedException, TimeoutException; 101 102 Object peek(long timeout) throws ChannelNotConnectedException, ChannelClosedException, TimeoutException; 103 104 void blockOk(); 105 106 boolean getState(Address target, long timeout) throws ChannelNotConnectedException, ChannelClosedException; 107 108 void returnState(byte[] state); 109 110 void returnState(byte[] state, String state_id); 111 } 112 | Popular Tags |