OverSim
|
#include <Gia.h>
Public Member Functions | |
void | initializeOverlay (int stage) |
initializes base class-attributes | |
void | finishOverlay () |
Writes statistical data and removes node from bootstrap oracle. | |
virtual void | changeState (int toStage) |
Set state to toStage. | |
void | updateTooltip () |
Marks nodes if they are ready. | |
~Gia () | |
Destructor. | |
void | handleTimerEvent (cMessage *msg) |
void | handleUDPMessage (BaseOverlayMessage *msg) |
Processes messages from underlay. | |
virtual void | getRoute (const OverlayKey &key, CompType destComp, CompType srcComp, cPacket *msg, const std::vector< TransportAddress > &sourceRoute=TransportAddress::UNSPECIFIED_NODES, RoutingType routingType=DEFAULT_ROUTING) |
void | handleAppMessage (cMessage *msg) |
Processes "timer" self-messages. | |
void | sendToken (const GiaNode &dst) |
Public Member Functions inherited from BaseOverlay | |
BaseOverlay () | |
virtual | ~BaseOverlay () |
Virtual destructor. | |
States | getState () |
bool | isMalicious () |
Returns true, if node is malicious. | |
bool | isInSimpleMultiOverlayHost () |
Returns true if overlay is one in an array, inside a SimpleMultiOverlayHost. | |
const simtime_t & | getCreationTime () |
void | join (const OverlayKey &nodeID=OverlayKey::UNSPECIFIED_KEY) |
Join the overlay with a given nodeID. | |
virtual NodeVector * | local_lookup (const OverlayKey &key, int num, bool safe) |
finds nodes closest to the given OverlayKey | |
virtual NodeVector * | neighborSet (int num) |
virtual bool | isSiblingFor (const NodeHandle &node, const OverlayKey &key, int numSiblings, bool *err) |
Query if a node is among the siblings for a given key. | |
virtual int | getMaxNumSiblings () |
Query the maximum number of siblings (nodes close to a key) that are maintained by this overlay protocol. | |
virtual int | getMaxNumRedundantNodes () |
Query the maximum number of redundant next hop nodes that are returned by findNode(). | |
void | sendMessageToUDP (const TransportAddress &dest, cPacket *msg, simtime_t delay=SIMTIME_ZERO) |
Sends message to underlay. | |
void | sendToKey (const OverlayKey &key, BaseOverlayMessage *message, int numSiblings=1, const std::vector< TransportAddress > &sourceRoute=TransportAddress::UNSPECIFIED_NODES, RoutingType routingType=DEFAULT_ROUTING) |
Sends a message to an overlay node, with the generic routing algorithm. | |
virtual OverlayKey | distance (const OverlayKey &x, const OverlayKey &y, bool useAlternative=false) const |
This method should implement the distance between two keys. | |
void | registerComp (CompType compType, cModule *module) |
cModule * | getCompModule (CompType compType) |
cGate * | getCompRpcGate (CompType compType) |
void | sendMessageToAllComp (cMessage *msg, CompType srcComp) |
bool | providesKbr () |
virtual uint8_t | getBitsPerDigit () |
bool | getMeasureAuthBlock () |
BootstrapList & | getBootstrapList () const |
virtual OverlayKey | estimateMeanDistance () |
returns mean distance between OverlayKeys in the network | |
virtual uint32_t | estimateOverlaySize () |
estimates the current number of nodes online | |
Public Member Functions inherited from BaseRpc | |
BaseRpc () | |
const NodeHandle & | getThisNode () |
Returns the NodeHandle of this node. | |
simtime_t | getUdpTimeout () |
Public Member Functions inherited from RpcListener | |
virtual | ~RpcListener () |
destructor | |
Public Member Functions inherited from BaseTcpSupport | |
virtual void | socketDataArrived (int connId, void *yourPtr, cPacket *msg, bool urgent) |
virtual void | socketEstablished (int connId, void *yourPtr) |
virtual void | socketPeerClosed (int connId, void *yourPtr) |
virtual void | socketFailure (int connId, void *yourPtr, int code) |
virtual void | socketStatusArrived (int connId, void *yourPtr, TCPStatusInfo *status) |
Public Member Functions inherited from TopologyVis | |
TopologyVis () | |
void | showOverlayNeighborArrow (const NodeHandle &neighbor, bool flush=true, const char *displayString=NULL) |
Draws an arrow from this node to neighbor. | |
void | deleteOverlayNeighborArrow (const NodeHandle &neighbor) |
Removes an arrow from this node to neighbor. |
Protected Member Functions | |
void | joinOverlay () |
Join the overlay with a given nodeID in thisNode.key. | |
bool | acceptNode (const GiaNode &newNode, unsigned int degree) |
Decides if Node newNode will be accepted as new neighor. | |
void | addNeighbor (GiaNode &newNode, unsigned int degree) |
Adds newNode as new neighbor. | |
void | removeNeighbor (const GiaNode &newNode) |
Removes newNode from our NeighborList. | |
double | calculateLevelOfSatisfaction () |
Calculates level of satisfaction. | |
void | sendMessage_JOIN_REQ (const NodeHandle &dst) |
Sends JOIN_REQ_Message from node src to node dst. | |
void | sendMessage_JOIN_RSP (const NodeHandle &dst) |
Sends JOIN_RSP_Message from node src to node dst. | |
void | sendMessage_JOIN_ACK (const NodeHandle &dst) |
Sends JOIN_ACK_Message from node src to node dst. | |
void | sendMessage_JOIN_DNY (const NodeHandle &dst) |
Sends JOIN_DNY_Message from node src to node dst. | |
void | sendMessage_DISCONNECT (const NodeHandle &dst) |
Sends DISCONNECT_Message from node src to node dst. | |
void | sendMessage_UPDATE (const NodeHandle &dst) |
Sends UPDATE_Message from node src to node dst. | |
void | sendKeyListToNeighbor (const NodeHandle &dst) |
Sends KeyList to node dst. | |
void | updateNeighborList (GiaMessage *msg) |
Updates neighborlist with new capacity and connectiondegree informations from received message msg. | |
void | forwardSearchResponseMessage (SearchResponseMessage *msg) |
Forwards a search response message to the next node in reverse-path. | |
void | forwardMessage (GiaIDMessage *msg, bool fromApplication) |
Forwards a message to the next random selected node, biased random walk. | |
void | processSearchMessage (SearchMessage *msg, bool fromApplication) |
Processes search message msg. | |
void | sendSearchResponseMessage (const GiaNode &srcNode, SearchMessage *msg) |
Sends a response message to a received search query. | |
void | deliverSearchResult (SearchResponseMessage *msg) |
Delivers search result to application layer. | |
Protected Member Functions inherited from BaseOverlay | |
int | numInitStages () const |
Sets init stage. | |
void | bindToPort (int port) |
Tells UDP we want to get all packets arriving on the given port. | |
virtual void | route (const OverlayKey &key, CompType destComp, CompType srcComp, cPacket *msg, const std::vector< TransportAddress > &sourceRoute=TransportAddress::UNSPECIFIED_NODES, RoutingType routingType=DEFAULT_ROUTING) |
Routes message through overlay. | |
void | callDeliver (BaseOverlayMessage *msg, const OverlayKey &destKey) |
Calls deliver function in application. | |
void | callForward (const OverlayKey &key, BaseRouteMessage *msg, const NodeHandle &nextHopNode) |
Calls forward function in application. | |
void | callUpdate (const NodeHandle &node, bool joined) |
Informs application about state changes of nodes or newly joined nodes. | |
void | handleMessage (cMessage *msg) |
Checks for message type and calls corresponding method. | |
void | handleBaseOverlayMessage (BaseOverlayMessage *msg, const OverlayKey &destKey=OverlayKey::UNSPECIFIED_KEY) |
Handles a BaseOverlayMessage | |
virtual void | receiveChangeNotification (int category, const cPolymorphic *details) |
callback-method for events at the NotificationBoard | |
virtual void | handleTransportAddressChangedNotification () |
This method gets call if the node has a new TransportAddress (IP address) because he changed his access network. | |
virtual void | handleNodeLeaveNotification () |
This method gets call **.gracefulLeaveDelay seconds before it is killed. | |
virtual void | handleNodeGracefulLeaveNotification () |
This method gets call **.gracefulLeaveDelay seconds before it is killed if this node is among the gracefulLeaveProbability nodes. | |
virtual void | recordOverlaySentStats (BaseOverlayMessage *msg) |
Collect overlay specific sent messages statistics. | |
void | setOverlayReady (bool ready) |
Sets the overlay ready icon and register/deregisters the node at the GlobalNodeList. | |
virtual AbstractLookup * | createLookup (RoutingType routingType=DEFAULT_ROUTING, const BaseOverlayMessage *msg=NULL, const cPacket *findNodeExt=NULL, bool appLookup=false) |
Creates an abstract iterative lookup instance. | |
virtual void | removeLookup (AbstractLookup *lookup) |
Removes the abstract lookup instance. | |
virtual NodeVector * | findNode (const OverlayKey &key, int numRedundantNodes, int numSiblings, BaseOverlayMessage *msg=NULL) |
Implements the find node call. | |
virtual void | joinForeignPartition (const NodeHandle &node) |
Join another overlay partition with the given node as bootstrap node. | |
virtual bool | handleFailedNode (const TransportAddress &failed) |
Handles a failed node. | |
virtual void | lookupRpc (LookupCall *call) |
virtual void | nextHopRpc (NextHopCall *call) |
void | countFindNodeCall (const FindNodeCall *call) |
void | countFailedNodeCall (const FailedNodeCall *call) |
bool | internalHandleRpcCall (BaseCallMessage *msg) |
Handles internal rpc requests. | |
void | internalHandleRpcResponse (BaseResponseMessage *msg, cPolymorphic *context, int rpcId, simtime_t rtt) |
Handles rpc responses internal in base classes | |
void | internalHandleRpcTimeout (BaseCallMessage *msg, const TransportAddress &dest, cPolymorphic *context, int rpcId, const OverlayKey &destKey) |
Handles rpc timeouts internal in base classes | |
void | internalSendRouteRpc (BaseRpcMessage *message, const OverlayKey &destKey, const std::vector< TransportAddress > &sourceRoute, RoutingType routingType) |
CompType | getThisCompType () |
Return the component type of this module. | |
Protected Member Functions inherited from BaseRpc | |
void | initRpcs () |
Initializes Remote-Procedure state. | |
void | finishRpcs () |
Deinitializes Remote-Procedure state. | |
virtual void | internalHandleRpcMessage (BaseRpcMessage *msg) |
Handles incoming rpc messages and delegates them to the corresponding listeners or handlers. | |
uint32_t | sendRouteRpcCall (CompType destComp, const TransportAddress &dest, const OverlayKey &destKey, BaseCallMessage *msg, cPolymorphic *context=NULL, RoutingType routingType=DEFAULT_ROUTING, simtime_t timeout=-1, int retries=0, int rpcId=-1, RpcListener *rpcListener=NULL) |
Routes a Remote-Procedure-Call message to an OverlayKey. | |
uint32_t | sendRouteRpcCall (CompType destComp, const OverlayKey &destKey, BaseCallMessage *msg, cPolymorphic *context=NULL, RoutingType routingType=DEFAULT_ROUTING, simtime_t timeout=-1, int retries=0, int rpcId=-1, RpcListener *rpcListener=NULL) |
Routes a Remote-Procedure-Call message to an OverlayKey. | |
uint32_t | sendRouteRpcCall (CompType destComp, const TransportAddress &dest, BaseCallMessage *msg, cPolymorphic *context=NULL, RoutingType routingType=DEFAULT_ROUTING, simtime_t timeout=-1, int retries=0, int rpcId=-1, RpcListener *rpcListener=NULL) |
Sends a Remote-Procedure-Call message using the overlay's UDP port This replaces ROUTE_DIRECT calls! | |
uint32_t | sendUdpRpcCall (const TransportAddress &dest, BaseCallMessage *msg, cPolymorphic *context=NULL, simtime_t timeout=-1, int retries=0, int rpcId=-1, RpcListener *rpcListener=NULL) |
Sends a Remote-Procedure-Call message to the underlay | |
uint32_t | sendInternalRpcCall (CompType destComp, BaseCallMessage *msg, cPolymorphic *context=NULL, simtime_t timeout=-1, int retries=0, int rpcId=-1, RpcListener *rpcListener=NULL) |
Sends an internal Remote-Procedure-Call between two tiers | |
void | cancelRpcMessage (uint32_t nonce) |
Cancels a Remote-Procedure-Call. | |
void | cancelAllRpcs () |
Cancels all RPCs. | |
void | sendRpcResponse (TransportType transportType, CompType destComp, const TransportAddress &dest, const OverlayKey &destKey, BaseCallMessage *call, BaseResponseMessage *response) |
Send Remote-Procedure response message and deletes call message. | |
void | sendRpcResponse (BaseCallMessage *call, BaseResponseMessage *response) |
Send Remote-Procedure response message to UDP and deletes call message. | |
int | pingNode (const TransportAddress &dest, simtime_t timeout=-1, int retries=0, cPolymorphic *context=NULL, const char *caption="PING", RpcListener *rpcListener=NULL, int rpcId=-1, TransportType transportType=INVALID_TRANSPORT) |
ping a node by its TransportAddress | |
virtual bool | handleRpcCall (BaseCallMessage *msg) |
Processes Remote-Procedure-Call invocation messages. | |
virtual void | pingResponse (PingResponse *pingResponse, cPolymorphic *context, int rpcId, simtime_t rtt) |
virtual void | pingTimeout (PingCall *pingCall, const TransportAddress &dest, cPolymorphic *context, int rpcId) |
bool | internalHandleMessage (cMessage *msg) |
Protected Member Functions inherited from RpcListener | |
virtual void | handleRpcResponse (BaseResponseMessage *msg, cPolymorphic *context, int rpcId, simtime_t rtt) |
This method is called if an RPC response has been received. | |
virtual void | handleRpcResponse (BaseResponseMessage *msg, const RpcState &rpcState, simtime_t rtt) |
This method is called if an RPC response has been received. | |
virtual void | handleRpcTimeout (BaseCallMessage *msg, const TransportAddress &dest, cPolymorphic *context, int rpcId, const OverlayKey &destKey) |
This method is called if an RPC timeout has been reached. | |
virtual void | handleRpcTimeout (const RpcState &rpcState) |
This method is called if an RPC timeout has been reached. | |
Protected Member Functions inherited from BaseTcpSupport | |
void | handleTCPMessage (cMessage *msg) |
Member function to handle incoming TCP messages. | |
void | bindAndListenTcp (int port) |
Member function to bind service to the specified port and listen afterwards. | |
bool | isAlreadyConnected (TransportAddress address) |
Member function to check if the service is already connected. | |
void | establishTcpConnection (TransportAddress address) |
Member function to establish a connection to the specified node. | |
void | sendTcpData (cPacket *msg, TransportAddress address) |
Member function to send TCP data to the specified node. | |
virtual void | handleConnectionEvent (EvCode code, TransportAddress address) |
Member function to handle passive connection events. | |
virtual void | handleDataReceived (TransportAddress address, cPacket *msg, bool urgent) |
Member function to handle incoming data. | |
virtual void | handleIncomingConnection (TransportAddress address) |
Member function to handle newly opened connections. | |
void | closeTcpConnection (TransportAddress address) |
Member function to close an established connection. | |
void | setTcpOut (cGate *gate) |
Member function to set local gate towards the TCP module during init phase. | |
cGate * | getTcpOut () |
Member function to get local gate towards the TCP module. | |
Protected Member Functions inherited from TopologyVis | |
void | initVis (cModule *terminal) |
Protected Attributes | |
uint32_t | maxNeighbors |
maximum number of neighbors | |
uint32_t | minNeighbors |
minimum number of neighbors | |
uint32_t | maxTopAdaptionInterval |
maximum topology adaption interval | |
uint32_t | topAdaptionAggressiveness |
the topology adaption aggressiveness | |
double | maxLevelOfSatisfaction |
maximum level of satisfaction | |
double | updateDelay |
time between to update messages (in ms) | |
uint32_t | maxHopCount |
maximum time to live for sent messages | |
uint32_t | messageTimeout |
timeout for messages | |
uint32_t | neighborTimeout |
timeout for neighbors | |
uint32_t | sendTokenTimeout |
timeout for tokens | |
uint32_t | tokenWaitTime |
delay to send a new token | |
double | keyListDelay |
delay to send the keylist to our neighbors | |
bool | outputNodeDetails |
output of node details? (on std::cout) | |
bool | optimizeReversePath |
use optimized reverse path? | |
double | levelOfSatisfaction |
current level of statisfaction | |
unsigned int | connectionDegree |
unsigned int | receivedTokens |
unsigned int | sentTokens |
GiaNode | thisGiaNode |
this node | |
NodeHandle | bootstrapNode |
next possible neighbor candidate | |
GiaMessageBookkeeping * | msgBookkeepingList |
pointer to a message bookkeeping list | |
uint32_t | stat_joinCount |
number of sent join messages | |
uint32_t | stat_joinBytesSent |
number of sent bytes of join messages | |
uint32_t | stat_joinREQ |
number of sent join request messages | |
uint32_t | stat_joinREQBytesSent |
number of sent bytes of join request messages | |
uint32_t | stat_joinRSP |
number of sent join response messages | |
uint32_t | stat_joinRSPBytesSent |
number of sent bytes of join response messages | |
uint32_t | stat_joinACK |
number of sent join acknowledge messages | |
uint32_t | stat_joinACKBytesSent |
number of sent bytes of join acknowledge messages | |
uint32_t | stat_joinDNY |
number of sent join deny messages | |
uint32_t | stat_joinDNYBytesSent |
number of sent bytes of join deny messages | |
uint32_t | stat_disconnectMessages |
number of sent disconnect messages | |
uint32_t | stat_disconnectMessagesBytesSent |
number of sent bytes of disconnect messages | |
uint32_t | stat_updateMessages |
number of sent update messages | |
uint32_t | stat_updateMessagesBytesSent |
number of sent bytes of update messages | |
uint32_t | stat_tokenMessages |
number of sent token messages | |
uint32_t | stat_tokenMessagesBytesSent |
number of sent bytes of token messages | |
uint32_t | stat_keyListMessages |
number of sent keylist messages | |
uint32_t | stat_keyListMessagesBytesSent |
number of sent bytes of keylist messages | |
uint32_t | stat_routeMessages |
number of sent route messages | |
uint32_t | stat_routeMessagesBytesSent |
number of sent bytes of route messages | |
uint32_t | stat_maxNeighbors |
maximum number of neighbors | |
uint32_t | stat_addedNeighbors |
number of added neighbors during life cycle of this node | |
uint32_t | stat_removedNeighbors |
number of removed neighbors during life cycle of this node | |
uint32_t | stat_numSatisfactionMessages |
number of satisfaction self-messages | |
double | stat_sumLevelOfSatisfaction |
sum of level of satisfaction | |
double | stat_maxLevelOfSatisfaction |
maximum level of satisfaction | |
cMessage * | satisfaction_timer |
timer for satisfaction self-message | |
cMessage * | update_timer |
timer for update self-message | |
cMessage * | timedoutMessages_timer |
timer for message timeout | |
cMessage * | timedoutNeighbors_timer |
timer for neighbors timeout | |
cMessage * | sendKeyList_timer |
timer for send keylist | |
cMessage * | sendToken_timer |
timer for send token | |
GiaKeyListModule * | keyListModule |
pointer to KeyListModule | |
GiaNeighbors * | neighbors |
pointer to neighbor list | |
GiaTokenFactory * | tokenFactory |
pointer to TokenFactory | |
GiaNeighborCandidateList | neighCand |
list of all neighbor candidates | |
GiaNeighborCandidateList | knownNodes |
list of known nodes in the overlay | |
GiaKeyList | keyList |
key list of this node | |
Protected Attributes inherited from BaseOverlay | |
int | numAppDataForwarded |
number of forwarded app data packets | |
int | bytesAppDataForwarded |
number of forwarded app data bytes at out-gate | |
int | numAppLookupForwarded |
number of forwarded app lookup packets | |
int | bytesAppLookupForwarded |
number of forwarded app lookup bytes at out-gate | |
int | numMaintenanceForwarded |
number of forwarded maintenance packets | |
int | bytesMaintenanceForwarded |
number of forwarded maintenance bytes at out-gate | |
int | numFindNodeSent |
int | bytesFindNodeSent |
int | numFindNodeResponseSent |
int | bytesFindNodeResponseSent |
int | numFailedNodeSent |
int | bytesFailedNodeSent |
int | numFailedNodeResponseSent |
int | bytesFailedNodeResponseSent |
std::vector< HopDelayRecord * > | singleHopDelays |
simtime_t | creationTime |
simtime when the node has been created | |
GlobalNodeList * | globalNodeList |
pointer to GlobalNodeList in this node | |
NotificationBoard * | notificationBoard |
pointer to NotificationBoard in this node | |
UnderlayConfigurator * | underlayConfigurator |
pointer to UnderlayConfigurator in this node | |
BootstrapList * | bootstrapList |
pointer to the BootstrapList module | |
GlobalParameters * | globalParameters |
pointer to the GlobalParameters module | |
uint32_t | overlayId |
identifies the overlay this node belongs to (used for multiple overlays) | |
bool | debugOutput |
debug output ? | |
RoutingType | defaultRoutingType |
bool | useCommonAPIforward |
forward messages to applications? | |
bool | collectPerHopDelay |
collect delay for single hops | |
bool | routeMsgAcks |
send ACK when receiving route message | |
uint32_t | recNumRedundantNodes |
numRedundantNodes for recursive routing | |
bool | recordRoute |
record visited hops on route | |
bool | drawOverlayTopology |
bool | rejoinOnFailure |
bool | sendRpcResponseToLastHop |
needed by KBR protocols for NAT support | |
bool | dropFindNodeAttack |
if node is malicious, it tries a findNode attack | |
bool | isSiblingAttack |
if node is malicious, it tries a isSibling attack | |
bool | invalidNodesAttack |
if node is malicious, it tries a invalidNode attack | |
bool | dropRouteMessageAttack |
if node is malicious, it drops all received BaseRouteMessages | |
int | localPort |
used UDP-port | |
int | hopCountMax |
maximum hop count | |
bool | measureAuthBlock |
if true, measure the overhead of signatures in rpc messages | |
bool | restoreContext |
if true, a node rejoins with its old nodeId and malicious state | |
int | numDropped |
number of dropped packets | |
int | bytesDropped |
number of dropped bytes | |
cOutVector | delayVector |
statistical output vector for packet-delays | |
cOutVector | hopCountVector |
statistical output vector for hop-counts | |
States | state |
IterativeLookupConfiguration | iterativeLookupConfig |
RecursiveLookupConfiguration | recursiveLookupConfig |
LookupSet | lookups |
bool | kbr |
set this to true, if the overlay provides KBR services | |
Protected Attributes inherited from BaseRpc | |
NodeHandle | thisNode |
NodeHandle to this node. | |
BaseOverlay * | overlay |
bool | debugOutput |
debug output ? | |
GlobalStatistics * | globalStatistics |
pointer to GlobalStatistics module in this node | |
CompType | thisCompType |
NeighborCache * | neighborCache |
pointer to the neighbor cache | |
CryptoModule * | cryptoModule |
pointer to CryptoModule | |
int | numPingSent |
int | bytesPingSent |
int | numPingResponseSent |
int | bytesPingResponseSent |
Protected Attributes inherited from TopologyVis | |
cModule * | thisTerminal |
GlobalNodeList * | globalNodeList |
pointer to corresponding node |
Additional Inherited Members | |
Public Types inherited from BaseOverlay | |
enum | States { INIT = 0, BOOTSTRAP = 1, DISCOVERY = 2, PREJOIN = 3, JOIN = 4, POSTJOIN = 5, READY = 6, REFRESH = 7, SHUTDOWN = 8, FAILED = 9, RSET = JOIN, BSET = POSTJOIN } |
Protected Types inherited from BaseOverlay | |
typedef UNORDERED_SET < AbstractLookup *, lookupHashFcn, lookupHashFcn > | LookupSet |
Gia overlay module.
Implementation of the Gia overlay as described in "Making Gnutella-like P2P Systems Scalable" by Y. Chawathe et al. published at SIGCOMM'03
Gia::~Gia | ( | ) |
Destructor.
Definition at line 1248 of file Gia.cc.
|
protected |
Decides if Node newNode will be accepted as new neighor.
newNode | Node to accept or deny |
degree | the node's connection degree |
Definition at line 569 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Adds newNode as new neighbor.
newNode | the node to add as a neighbor |
degree | the node's connection degree |
Definition at line 592 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Calculates level of satisfaction.
Definition at line 643 of file Gia.cc.
Referenced by handleTimerEvent().
|
virtual |
Set state to toStage.
toStage | the stage to change to |
Definition at line 124 of file Gia.cc.
Referenced by addNeighbor(), handleTimerEvent(), joinOverlay(), and removeNeighbor().
|
protected |
Delivers search result to application layer.
msg | Search response message |
Definition at line 1190 of file Gia.cc.
Referenced by forwardSearchResponseMessage(), and sendSearchResponseMessage().
|
virtual |
Writes statistical data and removes node from bootstrap oracle.
Reimplemented from BaseOverlay.
Definition at line 1212 of file Gia.cc.
|
protected |
Forwards a message to the next random selected node, biased random walk.
msg | Message to forward to next node |
fromApplication | Marks if message is from application layer |
Definition at line 872 of file Gia.cc.
Referenced by getRoute(), handleTimerEvent(), handleUDPMessage(), and processSearchMessage().
|
protected |
Forwards a search response message to the next node in reverse-path.
msg | Message to forward to next node |
Definition at line 828 of file Gia.cc.
Referenced by handleUDPMessage(), and sendSearchResponseMessage().
|
virtual |
Definition at line 1006 of file Gia.cc.
|
virtual |
Processes "timer" self-messages.
msg | A self-message Processes non-commonAPI messages |
msg | non-commonAPIMessage |
Reimplemented from BaseOverlay.
Definition at line 1040 of file Gia.cc.
|
virtual |
Reimplemented from BaseRpc.
Definition at line 261 of file Gia.cc.
|
virtual |
Processes messages from underlay.
msg | Message from UDP |
Reimplemented from BaseOverlay.
Definition at line 351 of file Gia.cc.
|
virtual |
initializes base class-attributes
stage | the init stage |
Reimplemented from BaseOverlay.
Definition at line 39 of file Gia.cc.
|
protectedvirtual |
Join the overlay with a given nodeID in thisNode.key.
Join the overlay with a given nodeID in thisNode.key. This method may be called by an application to join the overlay with a specific nodeID. It is also called if the node's IP address changes.
Reimplemented from BaseOverlay.
|
protected |
Processes search message msg.
Generates Search_Response_Messages
msg | Search message |
fromApplication | Marks if message is from application layer |
Definition at line 1147 of file Gia.cc.
Referenced by handleAppMessage(), and handleUDPMessage().
|
protected |
Removes newNode from our NeighborList.
newNode | NodeHandle of the node to remove from neighbors |
Definition at line 621 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Sends KeyList to node dst.
dst,: | Destination |
Definition at line 780 of file Gia.cc.
Referenced by addNeighbor(), and handleTimerEvent().
|
protected |
Sends DISCONNECT_Message from node src to node dst.
dst,: | Destination |
Definition at line 748 of file Gia.cc.
Referenced by acceptNode(), and handleUDPMessage().
|
protected |
Sends JOIN_ACK_Message from node src to node dst.
dst,: | Destination |
Definition at line 706 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Sends JOIN_DNY_Message from node src to node dst.
dst,: | Destination |
Definition at line 730 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Sends JOIN_REQ_Message from node src to node dst.
dst,: | Destination |
Definition at line 664 of file Gia.cc.
Referenced by handleTimerEvent().
|
protected |
Sends JOIN_RSP_Message from node src to node dst.
dst,: | Destination |
Definition at line 682 of file Gia.cc.
Referenced by handleUDPMessage().
|
protected |
Sends UPDATE_Message from node src to node dst.
dst,: | Destination |
Definition at line 764 of file Gia.cc.
Referenced by handleTimerEvent().
|
protected |
Sends a response message to a received search query.
srcNode | Node which contains the searched key |
msg | SearchMessage |
Definition at line 1084 of file Gia.cc.
Referenced by processSearchMessage().
void Gia::sendToken | ( | const GiaNode & | dst | ) |
Definition at line 801 of file Gia.cc.
Referenced by GiaTokenFactory::grantToken().
|
protected |
Updates neighborlist with new capacity and connectiondegree informations from received message msg.
msg | Received message |
Definition at line 819 of file Gia.cc.
Referenced by handleUDPMessage().
void Gia::updateTooltip | ( | ) |
Marks nodes if they are ready.
Definition at line 234 of file Gia.cc.
Referenced by addNeighbor(), changeState(), and removeNeighbor().
|
protected |
next possible neighbor candidate
Definition at line 134 of file Gia.h.
Referenced by changeState(), initializeOverlay(), and joinOverlay().
|
protected |
Definition at line 128 of file Gia.h.
Referenced by addNeighbor(), changeState(), forwardMessage(), getRoute(), handleAppMessage(), removeNeighbor(), sendKeyListToNeighbor(), sendMessage_DISCONNECT(), sendMessage_JOIN_ACK(), sendMessage_JOIN_DNY(), sendMessage_JOIN_REQ(), sendMessage_JOIN_RSP(), sendMessage_UPDATE(), sendSearchResponseMessage(), and sendToken().
|
protected |
key list of this node
Definition at line 181 of file Gia.h.
Referenced by addNeighbor(), handleAppMessage(), handleTimerEvent(), processSearchMessage(), and sendKeyListToNeighbor().
|
protected |
delay to send the keylist to our neighbors
Definition at line 123 of file Gia.h.
Referenced by handleAppMessage(), and initializeOverlay().
|
protected |
pointer to KeyListModule
Definition at line 174 of file Gia.h.
Referenced by handleAppMessage(), and initializeOverlay().
|
protected |
list of known nodes in the overlay
Definition at line 180 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), handleUDPMessage(), and initializeOverlay().
|
protected |
current level of statisfaction
Definition at line 127 of file Gia.h.
Referenced by calculateLevelOfSatisfaction(), handleTimerEvent(), and initializeOverlay().
|
protected |
maximum time to live for sent messages
Definition at line 118 of file Gia.h.
Referenced by changeState(), getRoute(), handleAppMessage(), initializeOverlay(), sendSearchResponseMessage(), and sendToken().
|
protected |
maximum level of satisfaction
Definition at line 116 of file Gia.h.
Referenced by handleTimerEvent(), and initializeOverlay().
|
protected |
maximum number of neighbors
Definition at line 112 of file Gia.h.
Referenced by acceptNode(), addNeighbor(), calculateLevelOfSatisfaction(), handleUDPMessage(), and initializeOverlay().
|
protected |
maximum topology adaption interval
Definition at line 114 of file Gia.h.
Referenced by handleTimerEvent(), and initializeOverlay().
|
protected |
timeout for messages
Definition at line 119 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), and initializeOverlay().
|
protected |
minimum number of neighbors
Definition at line 113 of file Gia.h.
Referenced by calculateLevelOfSatisfaction(), and initializeOverlay().
|
protected |
pointer to a message bookkeeping list
Definition at line 135 of file Gia.h.
Referenced by forwardMessage(), handleTimerEvent(), initializeOverlay(), and ~Gia().
|
protected |
pointer to neighbor list
Definition at line 175 of file Gia.h.
Referenced by acceptNode(), addNeighbor(), calculateLevelOfSatisfaction(), changeState(), forwardMessage(), forwardSearchResponseMessage(), handleTimerEvent(), handleUDPMessage(), initializeOverlay(), processSearchMessage(), removeNeighbor(), sendMessage_JOIN_ACK(), sendMessage_JOIN_RSP(), updateNeighborList(), and updateTooltip().
|
protected |
timeout for neighbors
Definition at line 120 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), and initializeOverlay().
|
protected |
list of all neighbor candidates
Definition at line 179 of file Gia.h.
Referenced by handleTimerEvent(), handleUDPMessage(), and initializeOverlay().
|
protected |
use optimized reverse path?
Definition at line 125 of file Gia.h.
Referenced by initializeOverlay(), and processSearchMessage().
|
protected |
output of node details? (on std::cout)
Definition at line 124 of file Gia.h.
Referenced by changeState(), and initializeOverlay().
|
protected |
Definition at line 129 of file Gia.h.
Referenced by changeState().
|
protected |
timer for satisfaction self-message
Definition at line 166 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), initializeOverlay(), and ~Gia().
|
protected |
timer for send keylist
Definition at line 170 of file Gia.h.
Referenced by handleAppMessage(), initializeOverlay(), and ~Gia().
|
protected |
timer for send token
Definition at line 171 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), initializeOverlay(), and ~Gia().
|
protected |
timeout for tokens
Definition at line 121 of file Gia.h.
Referenced by changeState(), and initializeOverlay().
|
protected |
Definition at line 130 of file Gia.h.
Referenced by changeState().
|
protected |
number of added neighbors during life cycle of this node
Definition at line 159 of file Gia.h.
Referenced by addNeighbor(), finishOverlay(), and initializeOverlay().
|
protected |
number of sent disconnect messages
Definition at line 148 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_DISCONNECT().
|
protected |
number of sent bytes of disconnect messages
Definition at line 149 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_DISCONNECT().
|
protected |
number of sent join acknowledge messages
Definition at line 144 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_ACK().
|
protected |
number of sent bytes of join acknowledge messages
Definition at line 145 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_ACK().
|
protected |
number of sent bytes of join messages
Definition at line 139 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), sendMessage_JOIN_ACK(), sendMessage_JOIN_DNY(), sendMessage_JOIN_REQ(), and sendMessage_JOIN_RSP().
|
protected |
number of sent join messages
Definition at line 138 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), sendMessage_JOIN_ACK(), sendMessage_JOIN_DNY(), sendMessage_JOIN_REQ(), and sendMessage_JOIN_RSP().
|
protected |
number of sent join deny messages
Definition at line 146 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_DNY().
|
protected |
number of sent bytes of join deny messages
Definition at line 147 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_DNY().
|
protected |
number of sent join request messages
Definition at line 140 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_REQ().
|
protected |
number of sent bytes of join request messages
Definition at line 141 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_REQ().
|
protected |
number of sent join response messages
Definition at line 142 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_RSP().
|
protected |
number of sent bytes of join response messages
Definition at line 143 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_JOIN_RSP().
|
protected |
number of sent keylist messages
Definition at line 154 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendKeyListToNeighbor().
|
protected |
number of sent bytes of keylist messages
Definition at line 155 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendKeyListToNeighbor().
|
protected |
maximum level of satisfaction
Definition at line 163 of file Gia.h.
Referenced by finishOverlay(), handleTimerEvent(), and initializeOverlay().
|
protected |
maximum number of neighbors
Definition at line 158 of file Gia.h.
Referenced by addNeighbor(), finishOverlay(), and initializeOverlay().
|
protected |
number of satisfaction self-messages
Definition at line 161 of file Gia.h.
Referenced by finishOverlay(), handleTimerEvent(), and initializeOverlay().
|
protected |
number of removed neighbors during life cycle of this node
Definition at line 160 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and removeNeighbor().
|
protected |
number of sent route messages
Definition at line 156 of file Gia.h.
Referenced by finishOverlay(), forwardMessage(), forwardSearchResponseMessage(), and initializeOverlay().
|
protected |
number of sent bytes of route messages
Definition at line 157 of file Gia.h.
Referenced by finishOverlay(), forwardMessage(), forwardSearchResponseMessage(), and initializeOverlay().
|
protected |
sum of level of satisfaction
Definition at line 162 of file Gia.h.
Referenced by finishOverlay(), handleTimerEvent(), and initializeOverlay().
|
protected |
number of sent token messages
Definition at line 152 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendToken().
|
protected |
number of sent bytes of token messages
Definition at line 153 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendToken().
|
protected |
number of sent update messages
Definition at line 150 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_UPDATE().
|
protected |
number of sent bytes of update messages
Definition at line 151 of file Gia.h.
Referenced by finishOverlay(), initializeOverlay(), and sendMessage_UPDATE().
|
protected |
this node
Definition at line 133 of file Gia.h.
Referenced by acceptNode(), addNeighbor(), calculateLevelOfSatisfaction(), changeState(), deliverSearchResult(), finishOverlay(), forwardMessage(), getRoute(), handleAppMessage(), handleTimerEvent(), handleUDPMessage(), initializeOverlay(), processSearchMessage(), removeNeighbor(), sendKeyListToNeighbor(), sendMessage_DISCONNECT(), sendMessage_JOIN_ACK(), sendMessage_JOIN_DNY(), sendMessage_JOIN_REQ(), sendMessage_JOIN_RSP(), sendMessage_UPDATE(), sendSearchResponseMessage(), and sendToken().
|
protected |
timer for message timeout
Definition at line 168 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), initializeOverlay(), and ~Gia().
|
protected |
timer for neighbors timeout
Definition at line 169 of file Gia.h.
Referenced by changeState(), handleTimerEvent(), initializeOverlay(), and ~Gia().
|
protected |
pointer to TokenFactory
Definition at line 176 of file Gia.h.
Referenced by changeState(), forwardMessage(), handleTimerEvent(), initializeOverlay(), and processSearchMessage().
|
protected |
delay to send a new token
Definition at line 122 of file Gia.h.
Referenced by forwardMessage(), and initializeOverlay().
|
protected |
the topology adaption aggressiveness
Definition at line 115 of file Gia.h.
Referenced by handleTimerEvent(), and initializeOverlay().
|
protected |
timer for update self-message
Definition at line 167 of file Gia.h.
Referenced by addNeighbor(), initializeOverlay(), removeNeighbor(), and ~Gia().
|
protected |
time between to update messages (in ms)
Definition at line 117 of file Gia.h.
Referenced by addNeighbor(), initializeOverlay(), and removeNeighbor().