|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object akka.cluster.Member
public class Member
Represents the address, current status, and roles of a cluster member node.
Note: hashCode
and equals
are solely based on the underlying Address
, not its MemberStatus
and roles.
Constructor Summary | |
---|---|
Member(UniqueAddress uniqueAddress,
int upNumber,
MemberStatus status,
scala.collection.immutable.Set<java.lang.String> roles)
|
Method Summary | |
---|---|
Address |
address()
INTERNAL API |
static scala.math.Ordering<Address> |
addressOrdering()
Address ordering type class, sorts addresses by host and port. |
static Member |
apply(UniqueAddress uniqueAddress,
scala.collection.immutable.Set<java.lang.String> roles)
INTERNAL API Create a new member with status Joining. |
Member |
copy(MemberStatus status)
|
Member |
copyUp(int upNumber)
|
boolean |
equals(java.lang.Object other)
|
java.util.Set<java.lang.String> |
getRoles()
Java API |
int |
hashCode()
|
boolean |
hasRole(java.lang.String role)
|
static Member |
highestPriorityOf(Member m1,
Member m2)
Picks the Member with the highest "priority" MemberStatus. |
boolean |
isOlderThan(Member other)
Is this member older, has been part of cluster longer, than another member. |
static scala.math.Ordering<Member> |
leaderStatusOrdering()
INTERNAL API Orders the members by their address except that members with status Joining, Exiting and Down are ordered last (in that order). |
static scala.collection.immutable.Set<Member> |
none()
|
static scala.math.Ordering<Member> |
ordering()
Member ordering type class, sorts members by host and port. |
static scala.collection.immutable.Set<Member> |
pickHighestPriority(scala.collection.immutable.Set<Member> a,
scala.collection.immutable.Set<Member> b)
|
static Member |
removed(UniqueAddress node)
INTERNAL API |
scala.collection.immutable.Set<java.lang.String> |
roles()
|
MemberStatus |
status()
|
java.lang.String |
toString()
|
UniqueAddress |
uniqueAddress()
|
int |
upNumber()
INTERNAL API |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Member(UniqueAddress uniqueAddress, int upNumber, MemberStatus status, scala.collection.immutable.Set<java.lang.String> roles)
Method Detail |
---|
public static scala.collection.immutable.Set<Member> none()
public static Member apply(UniqueAddress uniqueAddress, scala.collection.immutable.Set<java.lang.String> roles)
uniqueAddress
- (undocumented)roles
- (undocumented)
public static Member removed(UniqueAddress node)
node
- (undocumented)
public static scala.math.Ordering<Address> addressOrdering()
Address
ordering type class, sorts addresses by host and port.
public static scala.math.Ordering<Member> leaderStatusOrdering()
public static scala.math.Ordering<Member> ordering()
Member
ordering type class, sorts members by host and port.
public static scala.collection.immutable.Set<Member> pickHighestPriority(scala.collection.immutable.Set<Member> a, scala.collection.immutable.Set<Member> b)
public static Member highestPriorityOf(Member m1, Member m2)
m1
- (undocumented)m2
- (undocumented)
public UniqueAddress uniqueAddress()
public int upNumber()
public MemberStatus status()
public scala.collection.immutable.Set<java.lang.String> roles()
public Address address()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public boolean hasRole(java.lang.String role)
public java.util.Set<java.lang.String> getRoles()
public boolean isOlderThan(Member other)
other
- (undocumented)
public Member copy(MemberStatus status)
public Member copyUp(int upNumber)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |