|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--ostore.dtree.DTreeNode
The stage responsible for fulfilling the server's roles in various dissemination trees.
Stages (e.g. the inner ring) send updates, invalidations, and other responses to secondary replicas and clients via a multicast dissemination tree. This stage implements the protocols required for the server to participate in these trees as a parent, child, or both.
DownDTreeMsg
containing the message and the GUID for the
tree. That GUID will usually (always?) be the A-GUID for the data
object which the message concerns.
The local DTreeNode
stage will receive the
DownDTreeMsg
, extract the content message, and forward it
down the tree inside a DTreeMsg
using DD.
Conversely, to send a message up the dissemination tree,
dispatch a UpDTreeMsg
containing the message and the GUID for
the tree.
To join a dissemination tree, dispatch a JoinTreeReq
containing
the GUID for the tree. The DTreeNode
will attempt to
locate a current member of the tree (including the inner ring), using a
DTreeLocateMsg
requesting that member to tie the local node into
its tree. The remote node will return a JoinTreeResp
with the result
(success or failure), which this DTreeNode
will dispatch locally.
If the local server wishes to publish itself as an available secondary
replica for a data object, it should set the JoinTreeReq.publish
flag on its request to true
. The DTreeNode
stage will then publish the appropriate tag in DD.
DownDTreeMsg
,
UpDTreeMsg
,
JoinTreeReq
,
JoinTreeResp
,
DTreeMsg
,
DTreeLocateMsg
Field Summary | |
---|---|
protected static Double |
DEFAULT_DISTANCE_GUESS
The latency estimate to use for peers that don't appear in the RoutingTable . |
protected Map |
engines
A QSSignature->Signature map for storing verification
engines for the various signature algorithms used. |
protected static long |
MSG_TIMEOUT
The number of milliseconds to wait before resending messages. |
protected String |
name
The name by which to refer to this stage. |
protected Map |
node_states
A GUID->NodeState map storing the information for tree. |
protected static int |
NORMAL_LEASE
The length of a link lease, in bytes. |
protected Map |
pending_joins
A SecureHash->DTreeServiceReq map storing join requests,
indexed by their digests. |
protected static double |
REJOIN_DISTANCE_FACTOR
The factor by which a single tree rejoin action can increase this node's total latency from the tree root. |
protected static int |
RETRIES
The number of times to retry any message. |
protected static boolean |
USE_DISTANCE_METRIC
A flag that determines whether to rejoin trees using the depth metric (tree hops) or distance metric (latency in ms). |
Constructor Summary | |
---|---|
DTreeNode()
Initializes internal data structures. |
Method Summary | |
---|---|
void |
destroy()
|
void |
handleEvent(QueueElementIF elem)
|
void |
handleEvents(QueueElementIF[] elemarr)
|
void |
init(ConfigDataIF config)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static final long MSG_TIMEOUT
protected static final int RETRIES
protected static final int NORMAL_LEASE
protected static final Double DEFAULT_DISTANCE_GUESS
RoutingTable
.
protected static final boolean USE_DISTANCE_METRIC
protected static final double REJOIN_DISTANCE_FACTOR
protected String name
StageIF
.
protected Map node_states
GUID->NodeState
map storing the information for tree.
protected Map engines
QSSignature->Signature
map for storing verification
engines for the various signature algorithms used.
protected Map pending_joins
SecureHash->DTreeServiceReq
map storing join requests,
indexed by their digests.
Constructor Detail |
public DTreeNode()
Method Detail |
public void handleEvent(QueueElementIF elem) throws UnknownEventException
handleEvent
in interface EventHandlerIF
UnknownEventException
public void handleEvents(QueueElementIF[] elemarr) throws UnknownEventException
handleEvents
in interface EventHandlerIF
UnknownEventException
public void init(ConfigDataIF config) throws Exception
init
in interface EventHandlerIF
Exception
public void destroy()
destroy
in interface EventHandlerIF
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |