|
ePOST API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object rice.pastry.client.PastryAppl rice.pastry.standard.PeriodicLeafSetProtocol
public class PeriodicLeafSetProtocol
An implementation of a periodic-style leafset protocol
Field Summary | |
---|---|
int |
CHECK_LIVENESS_PERIOD
|
protected Credentials |
cred
|
protected java.util.WeakHashMap |
lastTimeReceivedBLS
NodeHandle -> Long remembers the TIME when we received a BLS from that NodeHandle |
protected LeafSet |
leafSet
|
protected NodeHandle |
localHandle
|
protected PastryNode |
localNode
|
int |
PING_NEIGHBOR_PERIOD
Related to rapidly determining direct neighbor liveness. |
protected RoutingTable |
routeTable
|
protected PastrySecurityManager |
security
|
Fields inherited from class rice.pastry.client.PastryAppl |
---|
address, instance, logger, thePastryNode |
Constructor Summary | |
---|---|
PeriodicLeafSetProtocol(PastryNode ln,
NodeHandle local,
PastrySecurityManager sm,
LeafSet ls,
RoutingTable rt)
Builds a periodic leafset protocol |
Method Summary | |
---|---|
protected void |
broadcastAll()
Broadcast the leaf set to all members of the local leaf set. |
boolean |
deliverWhenNotReady()
We always want to receive messages. |
void |
destroy()
Called when PastryNode is destroyed. |
Address |
getAddress()
Get address. |
Credentials |
getCredentials()
Returns the credentials of this application. |
void |
messageForAppl(Message msg)
Should not be called becasue we are overriding the receiveMessage() interface anyway. |
void |
receiveMessage(Message msg)
Receives messages. |
Methods inherited from class rice.pastry.client.PastryAppl |
---|
enrouteMessage, getLeafSet, getNodeHandle, getNodeId, getRoutingTable, isClosest, leafSetChange, notifyReady, register, registerReceiver, routeMsg, routeMsgDirect, routeSetChange, sendMessage |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected NodeHandle localHandle
protected PastryNode localNode
protected PastrySecurityManager security
protected LeafSet leafSet
protected RoutingTable routeTable
protected java.util.WeakHashMap lastTimeReceivedBLS
public final int PING_NEIGHBOR_PERIOD
public final int CHECK_LIVENESS_PERIOD
protected Credentials cred
Constructor Detail |
---|
public PeriodicLeafSetProtocol(PastryNode ln, NodeHandle local, PastrySecurityManager sm, LeafSet ls, RoutingTable rt)
Method Detail |
---|
public void receiveMessage(Message msg)
receiveMessage
in interface MessageReceiver
receiveMessage
in class PastryAppl
msg
- the message.protected void broadcastAll()
type
- the type of broadcast message usedpublic void messageForAppl(Message msg)
messageForAppl
in class PastryAppl
msg
- the message that is arriving.public Credentials getCredentials()
PastryAppl
getCredentials
in class PastryAppl
public Address getAddress()
getAddress
in class PastryAppl
public boolean deliverWhenNotReady()
deliverWhenNotReady
in class PastryAppl
public void destroy()
PastryAppl
destroy
in class PastryAppl
|
ePOST API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |