forest-net
an overlay networks for large-scale virtual worlds
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator
ComtCtl.h File Reference
#include <pthread.h>
#include "Forest.h"
#include "Packet.h"
#include "PacketStoreTs.h"
#include "NetInfo.h"
#include "ComtInfo.h"
#include "UiSetPair.h"
#include "IdMap.h"
#include "Heap.h"
#include "Queue.h"
#include "NetBuffer.h"
#include "Logger.h"
#include "Substrate.h"
#include "CpHandler.h"
#include <map>
Include dependency graph for ComtCtl.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  forest::QueuePair
 
struct  forest::EventStruct
 
struct  forest::ThreadInfo
 

Namespaces

 forest
 The CtlPkt class is used to pack and unpack forest control messages.
 

Constant Groups

 forest
 The CtlPkt class is used to pack and unpack forest control messages.
 

Functions

bool forest::init (ipa_t, ipa_t, int, int, const char *topoFile)
 
bool forest::bootMe (ipa_t nmIp, ipa_t myIp, fAdr_t &nmAdr, fAdr_t &myAdr, fAdr_t &rtrAdr, ipa_t &rtrIp, ipp_t &rtrPort, uint64_t &nonce)
 Send a boot request to NetMgr and process configuraton packets. More...
 
void forest::cleanup ()
 
void * forest::run (void *)
 
void * forest::handler (void *qp)
 Control packet handler. More...
 
bool forest::handleComtreeDisplay (int)
 
bool forest::handleAddComtReq (int, CtlPkt &, CpHandler &)
 
bool forest::handleDropComtReq (int, CtlPkt &, CpHandler &)
 
bool forest::handleJoinComtReq (int, CtlPkt &, CpHandler &)
 
bool forest::handleLeaveComtReq (int, CtlPkt &, CpHandler &)
 
bool forest::handleComtPath (int, CtlPkt &, CpHandler &)
 
bool forest::handleComtNewLeaf (int, CtlPkt &, CpHandler &)
 
bool forest::handleComtPrune (int, CtlPkt &, CpHandler &)
 
void forest::removeSubtree (int, fAdr_t)
 
int forest::newComtreeNum ()
 
void forest::releaseComtreeNum (int)
 
bool forest::setupPath (int, list< LinkMod > &, CpHandler &)
 
bool forest::teardownPath (int, list< LinkMod > &, CpHandler &)
 
bool forest::setupComtNode (int, int, CpHandler &)
 
bool forest::teardownComtNode (int, int, CpHandler &)
 
bool forest::setupComtLink (int, int, int, CpHandler &)
 
int forest::setupClientLink (int, fAdr_t, int, CpHandler &)
 
bool forest::teardownClientLink (int, fAdr_t, int, CpHandler &)
 
bool forest::setupComtAttrs (int, int, CpHandler &)
 
bool forest::setComtLinkRates (int, int, int, CpHandler &)
 
bool forest::setComtLeafRates (int, fAdr_t, CpHandler &)
 
bool forest::modComtRates (int, list< LinkMod > &, bool, CpHandler &)
 
void forest::connect ()
 
void forest::disconnect ()
 
void forest::sendToRemote (int)
 
int forest::recvFromRemote ()
 
void forest::sendToForest (int)
 
int forest::rcvFromForest ()
 

Variables

NetInfo * forest::net
 global view of net topology
 
ComtInfo * forest::comtrees
 definition of all comtrees More...
 
int forest::maxComtree
 max# of comtrees
 
int forest::firstComt
 
int forest::lastComt
 defines range of comtrees controlled
 
UiSetPair * forest::comtSet
 in-use and unused comtrees
 
pthread_mutex_t forest::comtSetLock
 used to lock comtSet
 
static const int forest::NORESPONSE = (1 << 31)
 indicates non-response to ctl pkt
 
static const int forest::TPSIZE = 500
 number of concurrent threads at ComtCtl
 
ThreadInfo * forest::pool
 pool[i]: i-th thread in pool
 
UiSetPair * forest::threads
 in-use and unused thread indices
 
IdMap * forest::reqMap
 maps rcvd requests to handling thread
 
IdMap * forest::tMap
 maps sequence numbers to thread index
 

Detailed Description

Author
Jon Turner
Date
2011 This is open source software licensed under the Apache 2.0 license. See http://www.apache.org/licenses/LICENSE-2.0 for details.

Definition in file ComtCtl.h.