パッケージ org.piax.gtrans.ov.ring
クラス RingVNode<E extends Endpoint>
java.lang.Object
org.piax.gtrans.ov.ring.RingVNode<E>
- 型パラメータ:
E- the type of Endpoint in the underlying network.
- すべての実装されたインタフェース:
NodeObserver
- 直系の既知のサブクラス:
RQVNode
public class RingVNode<E extends Endpoint> extends Object implements NodeObserver
a virtual node in simple ring network.
-
ネストされたクラスの概要
ネストされたクラス 修飾子とタイプ クラス 説明 static classRingVNode.VNodeModemode of DdllRingVNode -
フィールドの概要
フィールド 修飾子とタイプ フィールド 説明 static booleanDDLL_OPTtrue to turn on DDLL-OPTstatic intDDLL_RETRY_INTERVALprotected NodeddllNodestatic intDEFAULT_DDLL_CHECK_PERIODprotected DdllKeykeyprotected RingManager<E>managerprotected RingVNode.VNodeModemodestatic intNUMBER_OF_DDLL_RETRY -
コンストラクタの概要
コンストラクタ コンストラクタ 説明 RingVNode(RingManager<E> rman, Comparable<?> rawkey)create a RingVNode instance. -
メソッドの概要
修飾子とタイプ メソッド 説明 protected booleanaddKey(E introducer)insert a key into a ring.voidfixLeftLinks(Link link, List<Link> failedLinks, RQMessage msg, List<Range<DdllKey>> failedRanges)Link[]getAllLinks()protected static intgetCheckPeriod()NodegetDdllNode()DdllKeygetKey()get DdllKeyLinkgetLocalLink()RingManager<E>getManager()RingVNode.VNodeModegetMode()LinkgetPredecessor()Comparable<?>getRawKey()get raw keyLinkgetSuccessor()booleanisInserted()booleanonNodeFailure(Collection<Link> failedLinks)called when node failure is detected by DDLL's node monitor.voidonRightNodeChange(Link prevRight, Link newRight, Object payload)called when the right link is changed by receiving a SetR message.voidpayloadNotSent(Object payload)called when the payload given viaNode.setR(Link, int, Link, Link, LinkSeq, int, Object)is not passed to the specified remote node.protected booleanremoveKey()protected voidrtLockR()protected voidrtLockW()protected voidrtUnlockR()protected voidrtUnlockW()List<Link>suppplyLeftCandidatesForFix()StringtoString()StringtoStringRoutingTable()
-
フィールド詳細
-
DEFAULT_DDLL_CHECK_PERIOD
public static final int DEFAULT_DDLL_CHECK_PERIOD- 関連項目:
- 定数フィールド値
-
NUMBER_OF_DDLL_RETRY
public static final int NUMBER_OF_DDLL_RETRY- 関連項目:
- 定数フィールド値
-
DDLL_RETRY_INTERVAL
public static final int DDLL_RETRY_INTERVAL- 関連項目:
- 定数フィールド値
-
DDLL_OPT
public static final boolean DDLL_OPTtrue to turn on DDLL-OPT- 関連項目:
- 定数フィールド値
-
manager
-
key
-
ddllNode
-
mode
-
-
コンストラクタの詳細
-
RingVNode
create a RingVNode instance.- パラメータ:
rman- the p2p network instance that manages this noderawkey- the key
-
-
メソッドの詳細
-
getCheckPeriod
protected static int getCheckPeriod() -
getDdllNode
-
getMode
-
getLocalLink
-
getSuccessor
-
getPredecessor
-
getAllLinks
-
rtLockR
protected void rtLockR() -
rtUnlockR
protected void rtUnlockR() -
rtLockW
protected void rtLockW() -
rtUnlockW
protected void rtUnlockW() -
addKey
insert a key into a ring.- パラメータ:
introducer- 既に挿入済みのノード- 戻り値:
- 成功したらtrue
- 例外:
UnavailableException- introducerにkeyが存在しないIOException- introducerとの通信でエラー or insertion failure
-
removeKey
protected boolean removeKey() -
toString
-
toStringRoutingTable
-
isInserted
public boolean isInserted() -
getRawKey
get raw key- 戻り値:
- raw key
-
getKey
get DdllKey- 戻り値:
- DdllKey
-
getManager
-
fixLeftLinks
-
onRightNodeChange
インタフェースからコピーされた説明:NodeObservercalled when the right link is changed by receiving a SetR message.- 定義:
onRightNodeChangeインタフェース内NodeObserver- パラメータ:
prevRight- the previous right linknewRight- the new right linkpayload- an Object passed with SetR message.- 関連項目:
Node.setR(Link, int, Link, Link, LinkSeq, int, Object)
-
payloadNotSent
インタフェースからコピーされた説明:NodeObservercalled when the payload given viaNode.setR(Link, int, Link, Link, LinkSeq, int, Object)is not passed to the specified remote node. typically this happens when the SetR request fails.- 定義:
payloadNotSentインタフェース内NodeObserver- パラメータ:
payload- the payload not has been sent
-
onNodeFailure
インタフェースからコピーされた説明:NodeObservercalled when node failure is detected by DDLL's node monitor. if this method returns true, the DDLL link fixing procedure is executed just after returning from this method. when false is returned, it is application's responsibility to repair the failed link.- 定義:
onNodeFailureインタフェース内NodeObserver- パラメータ:
failedLinks- the collection of failed links.- 戻り値:
- true to execute DDLL's link fixing procedure
-
suppplyLeftCandidatesForFix
- 定義:
suppplyLeftCandidatesForFixインタフェース内NodeObserver
-