📄 clustermanager.html
字号:
Before starting a cluster the <A HREF="../../../../org/jivesoftware/openfire/XMPPServer.html#setRemoteSessionLocator(org.jivesoftware.openfire.session.RemoteSessionLocator)"><CODE>XMPPServer.setRemoteSessionLocator(org.jivesoftware.openfire.session.RemoteSessionLocator)</CODE></A> and <A HREF="../../../../org/jivesoftware/openfire/RoutingTable.html#setRemotePacketRouter(org.jivesoftware.openfire.RemotePacketRouter)"><CODE>RoutingTable.setRemotePacketRouter(org.jivesoftware.openfire.RemotePacketRouter)</CODE></A> need to be properly configured.<P><DD><DL></DL></DD></DL><HR><A NAME="shutdown()"><!-- --></A><H3>shutdown</H3><PRE>public static void <B>shutdown</B>()</PRE><DL><DD>Shuts down the clustering service. This method should be called when the Jive system is shutting down, and must not be called otherwise. Failing to call this method may temporarily impact cluster performance, as the system will have to do extra work to recover from a non-clean shutdown. If clustering is not enabled, this method will do nothing.<P><DD><DL></DL></DD></DL><HR><A NAME="setClusteringEnabled(boolean)"><!-- --></A><H3>setClusteringEnabled</H3><PRE>public static void <B>setClusteringEnabled</B>(boolean enabled)</PRE><DL><DD>Sets true if clustering support is enabled. An attempt to start or join an existing cluster will be attempted in the service was enabled. On the other hand, if disabled then this JVM will leave or stop the cluster.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>enabled</CODE> - if clustering support is enabled.</DL></DD></DL><HR><A NAME="isClusteringEnabled()"><!-- --></A><H3>isClusteringEnabled</H3><PRE>public static boolean <B>isClusteringEnabled</B>()</PRE><DL><DD>Returns true if clustering support is enabled. This does not mean that clustering has started or that clustering will be able to start.<P><DD><DL><DT><B>Returns:</B><DD>true if clustering support is enabled.</DL></DD></DL><HR><A NAME="isClusteringAvailable()"><!-- --></A><H3>isClusteringAvailable</H3><PRE>public static boolean <B>isClusteringAvailable</B>()</PRE><DL><DD>Returns true if clustering is installed and can be used by this JVM to join a cluster. A false value could mean that either clustering support is not available or the license does not allow to have more than 1 cluster node.<P><DD><DL><DT><B>Returns:</B><DD>true if clustering is installed and can be used by this JVM to join a cluster.</DL></DD></DL><HR><A NAME="isClusteringStarting()"><!-- --></A><H3>isClusteringStarting</H3><PRE>public static boolean <B>isClusteringStarting</B>()</PRE><DL><DD>Returns true is clustering is currently being started. Once the cluster is started or failed to be started this value will be false.<P><DD><DL><DT><B>Returns:</B><DD>true is clustering is currently being started.</DL></DD></DL><HR><A NAME="isClusteringStarted()"><!-- --></A><H3>isClusteringStarted</H3><PRE>public static boolean <B>isClusteringStarted</B>()</PRE><DL><DD>Returns true if this JVM is part of a cluster. The cluster may have many nodes or this JVM could be the only node.<P><DD><DL><DT><B>Returns:</B><DD>true if this JVM is part of a cluster.</DL></DD></DL><HR><A NAME="isSeniorClusterMember()"><!-- --></A><H3>isSeniorClusterMember</H3><PRE>public static boolean <B>isSeniorClusterMember</B>()</PRE><DL><DD>Returns true if this member is the senior member in the cluster. If clustering is not enabled, this method will also return true. This test is useful for tasks that should only be run on a single member in a cluster.<P><DD><DL><DT><B>Returns:</B><DD>true if this cluster member is the senior or if clustering is not enabled.</DL></DD></DL><HR><A NAME="getNodesInfo()"><!-- --></A><H3>getNodesInfo</H3><PRE>public static <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A><<A HREF="../../../../org/jivesoftware/openfire/cluster/ClusterNodeInfo.html" title="interface in org.jivesoftware.openfire.cluster">ClusterNodeInfo</A>> <B>getNodesInfo</B>()</PRE><DL><DD>Returns basic information about the current members of the cluster or an empty collection if not running in a cluster.<P><DD><DL><DT><B>Returns:</B><DD>information about the current members of the cluster or an empty collection if not running in a cluster.</DL></DD></DL><HR><A NAME="getMaxClusterNodes()"><!-- --></A><H3>getMaxClusterNodes</H3><PRE>public static int <B>getMaxClusterNodes</B>()</PRE><DL><DD>Returns the maximum number of cluster members allowed. Both values 0 and 1 mean that clustering is not available. However, a value of 1 means that it's a license problem rather than not having the ability to do clustering as defined with value 0.<P><DD><DL><DT><B>Returns:</B><DD>the maximum number of cluster members allowed or 0 or 1 if clustering is not allowed.</DL></DD></DL><HR><A NAME="getSeniorClusterMember()"><!-- --></A><H3>getSeniorClusterMember</H3><PRE>public static <A HREF="../../../../org/jivesoftware/openfire/cluster/NodeID.html" title="class in org.jivesoftware.openfire.cluster">NodeID</A> <B>getSeniorClusterMember</B>()</PRE><DL><DD>Returns the id of the node that is the senior cluster member. When not in a cluster the returned node id will be the <A HREF="../../../../org/jivesoftware/openfire/XMPPServer.html#getNodeID()"><CODE>XMPPServer.getNodeID()</CODE></A>.<P><DD><DL><DT><B>Returns:</B><DD>the id of the node that is the senior cluster member.</DL></DD></DL><HR><A NAME="isClusterMember(byte[])"><!-- --></A><H3>isClusterMember</H3><PRE>public static boolean <B>isClusterMember</B>(byte[] nodeID)</PRE><DL><DD>Returns true if the specified node ID belongs to a known cluster node of this cluster.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>nodeID</CODE> - the ID of the node to verify.<DT><B>Returns:</B><DD>true if the specified node ID belongs to a known cluster node of this cluster.</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Openfire 3.6.0a Javadoc</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../org/jivesoftware/openfire/cluster/ClusterEventListener.html" title="interface in org.jivesoftware.openfire.cluster"><B>PREV CLASS</B></A> <A HREF="../../../../org/jivesoftware/openfire/cluster/ClusterNodeInfo.html" title="interface in org.jivesoftware.openfire.cluster"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../index.html?org/jivesoftware/openfire/cluster/ClusterManager.html" target="_top"><B>FRAMES</B></A> <A HREF="ClusterManager.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT> <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR><i>Copyright © 2003-2008 Jive Software.</i></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -