[jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication ...
Brian Stansberry
brian.stansberry at jboss.com
Tue Oct 10 16:48:56 EDT 2006
User: bstansberry
Date: 06/10/10 16:48:56
Modified: src/org/jboss/cache/buddyreplication Tag:
Branch_JBossCache_1_4_0 BuddyLocator.java
Log:
Javadoc.
Revision Changes Path
No revision
No revision
1.1.2.1 +25 -0 JBossCache/src/org/jboss/cache/buddyreplication/BuddyLocator.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: BuddyLocator.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyLocator.java,v
retrieving revision 1.1
retrieving revision 1.1.2.1
diff -u -b -r1.1 -r1.1.2.1
--- BuddyLocator.java 24 Apr 2006 10:15:29 -0000 1.1
+++ BuddyLocator.java 10 Oct 2006 20:48:56 -0000 1.1.2.1
@@ -14,12 +14,37 @@
/**
* Buddy Locators help the {@see BuddyManager} select buddies for its buddy group.
+ * <p>
+ * Implementations of this class must declard a public no-arguments constructor.
+ * </p>
*
* @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
*/
public interface BuddyLocator
{
+ /**
+ * Initialize this <code>BuddyLocator</code>.
+ *
+ * @param props an implementation-specific set of configuration properties.
+ * May be <code>null</code>.
+ */
public void init(Properties props);
+ /**
+ * Choose a set of buddies for the given node. Invoked when a change in
+ * cluster membership is detected.
+ *
+ * @param buddyPoolMap Map<IpAddress, String> mapping nodes in the cluster to
+ * the "buddy pool" they have identified themselves as
+ * belonging too. A BuddyLocator implementation can use
+ * this information to preferentially assign buddies from
+ * the same buddy pool as <code>dataOwner</code>.
+ * @param currentMembership List<IpAddress> of the current cluster members
+ * @param dataOwner IpAddress of the node for which buddies should be selected
+ *
+ * @return List<IpAddress> of the nodes that should serve as buddies for
+ * <code>dataOwner</code>. Will not be <code>null</code>, may
+ * be empty.
+ */
public List locateBuddies(Map buddyPoolMap, List currentMembership, IpAddress dataOwner);
}
More information about the jboss-cvs-commits
mailing list