ariba::overlay::Chord Class Reference

#include <source/ariba/overlay/modules/chord/Chord.h>

Inherits ariba::overlay::OverlayInterface, and ariba::utility::Timer.

Collaboration diagram for ariba::overlay::Chord:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 Chord (BaseOverlay &_baseoverlay, const NodeID &_nodeid, OverlayStructureEvents *_eventsReceiver, const OverlayParameterSet &param)
virtual ~Chord ()
virtual const LinkIDgetNextLinkId (const NodeID &id) const
virtual void createOverlay ()
virtual void deleteOverlay ()
virtual void joinOverlay (const EndpointDescriptor &boot=EndpointDescriptor::UNSPECIFIED())
virtual void leaveOverlay ()
virtual const EndpointDescriptorresolveNode (const NodeID &node)
virtual NodeList getKnownNodes (bool deep=true) const
virtual void onLinkUp (const LinkID &lnk, const NodeID &remote)
virtual void onLinkDown (const LinkID &lnk, const NodeID &remote)
virtual void onMessage (const DataMessage &msg, const NodeID &remote, const LinkID &lnk=LinkID::UNSPECIFIED)
virtual void eventFunction ()

Private Member Functions

 use_logging_h (Chord)
LinkID setup (const EndpointDescriptor &endp, const NodeID &node=NodeID::UNSPECIFIED)
 helper: sets up a link using the base overlay
seqnum_t send (OverlayMsg *msg, const LinkID &link)
 helper: sends a message using the "base overlay"
void send_discovery_to (const NodeID &destination, int ttl=3)
 sends a discovery message
void discover_neighbors (const LinkID &lnk)
void showLinks ()

Private Attributes

chord_routing_tabletable
int orphan_removal_counter
int stabilize_counter
int stabilize_finger
vector< LinkIDbootstrapLinks
vector< NodeIDpending
vector< NodeIDdiscovery
int discovery_count


Detailed Description

This class implements a structured overlay inspired by chord. It differs to the original form of chord in the following manner:

(1) The graph is bidirectional (2) Stabilization is done in a reactive manner

It therefore can be considered as a kind of Chorded-Kademlia :)

The resulting overlay graph has a diameter of O(log N).

Author:
Sebastian Mies <mies@tm.uka.de>

Definition at line 73 of file Chord.h.


Constructor & Destructor Documentation

ariba::overlay::Chord::Chord ( BaseOverlay _baseoverlay,
const NodeID _nodeid,
OverlayStructureEvents _eventsReceiver,
const OverlayParameterSet param 
)

ariba::overlay::Chord::~Chord (  )  [virtual]

Definition at line 71 of file Chord.cpp.

References table.


Member Function Documentation

void ariba::overlay::Chord::createOverlay (  )  [virtual]

See also:
OverlayInterface.h

Implements ariba::overlay::OverlayInterface.

Definition at line 149 of file Chord.cpp.

void ariba::overlay::Chord::deleteOverlay (  )  [virtual]

See also:
OverlayInterface.h

Implements ariba::overlay::OverlayInterface.

Definition at line 152 of file Chord.cpp.

void ariba::overlay::Chord::discover_neighbors ( const LinkID lnk  )  [private]

void ariba::overlay::Chord::eventFunction (  )  [virtual]

OverlayInterface::NodeList ariba::overlay::Chord::getKnownNodes ( bool  deep = true  )  const [virtual]

const LinkID & ariba::overlay::Chord::getNextLinkId ( const NodeID id  )  const [virtual]

void ariba::overlay::Chord::joinOverlay ( const EndpointDescriptor boot = EndpointDescriptor::UNSPECIFIED()  )  [virtual]

void ariba::overlay::Chord::leaveOverlay (  )  [virtual]

void ariba::overlay::Chord::onLinkDown ( const LinkID lnk,
const NodeID remote 
) [virtual]

void ariba::overlay::Chord::onLinkUp ( const LinkID lnk,
const NodeID remote 
) [virtual]

void ariba::overlay::Chord::onMessage ( const DataMessage msg,
const NodeID remote,
const LinkID link = LinkID::UNSPECIFIED 
) [virtual]

const EndpointDescriptor & ariba::overlay::Chord::resolveNode ( const NodeID node  )  [virtual]

seqnum_t ariba::overlay::Chord::send ( OverlayMsg msg,
const LinkID link 
) [private]

helper: sends a message using the "base overlay"

Definition at line 104 of file Chord.cpp.

References ariba::overlay::OverlayInterface::baseoverlay, ariba::utility::Identifier::isUnspecified(), and ariba::overlay::BaseOverlay::send_link().

Referenced by discover_neighbors(), and leaveOverlay().

void ariba::overlay::Chord::send_discovery_to ( const NodeID destination,
int  ttl = 3 
) [private]

LinkID ariba::overlay::Chord::setup ( const EndpointDescriptor endp,
const NodeID node = NodeID::UNSPECIFIED 
) [private]

void ariba::overlay::Chord::showLinks (  )  [private]

ariba::overlay::Chord::use_logging_h ( Chord   )  [private]


Member Data Documentation

Definition at line 80 of file Chord.h.

Referenced by joinOverlay(), and onLinkUp().

Definition at line 82 of file Chord.h.

Referenced by eventFunction(), and onMessage().

Definition at line 83 of file Chord.h.

Referenced by Chord().

Definition at line 77 of file Chord.h.

Referenced by Chord(), and eventFunction().

Definition at line 81 of file Chord.h.

Referenced by eventFunction(), onLinkUp(), and setup().

Definition at line 78 of file Chord.h.

Referenced by Chord(), and eventFunction().

Definition at line 79 of file Chord.h.

Referenced by Chord(), and eventFunction().


The documentation for this class was generated from the following files:

Generated on Fri Aug 14 23:39:24 2009 for Ariba by  doxygen 1.5.8