OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
BgpSenderPartition Class Reference

#include <bgp_update_sender.h>

Collaboration diagram for BgpSenderPartition:

Classes

struct  PeerRibState
 
class  PeerState
 
class  RibState
 
struct  WorkBase
 
class  Worker
 
struct  WorkPeer
 
struct  WorkRibOut
 

Public Member Functions

 BgpSenderPartition (BgpUpdateSender *sender, int index)
 
 ~BgpSenderPartition ()
 
void Add (RibOut *ribout, IPeerUpdate *peer)
 
void Remove (RibOut *ribout, IPeerUpdate *peer)
 
void RibOutActive (RibOut *ribout, int queue_id)
 
void PeerSendReady (IPeerUpdate *peer)
 
bool PeerIsSendReady (IPeerUpdate *peer) const
 
bool PeerIsRegistered (IPeerUpdate *peer) const
 
bool PeerInSync (IPeerUpdate *peer) const
 
bool CheckInvariants () const
 
int task_id () const
 
int index () const
 
void set_disabled (bool disabled)
 

Private Types

typedef boost::ptr_list< WorkBaseWorkQueue
 
typedef IndexMap< IPeerUpdate
*, PeerState
PeerStateMap
 
typedef IndexMap< RibOut
*, RibState
RibStateMap
 

Private Member Functions

void MaybeStartWorker ()
 
std::unique_ptr< WorkBaseWorkDequeue ()
 
void WorkEnqueue (WorkBase *wentry)
 
void WorkPeerEnqueue (IPeerUpdate *peer)
 
void WorkPeerInvalidate (IPeerUpdate *peer)
 
void WorkRibOutEnqueue (RibOut *ribout, int queue_id)
 
void WorkRibOutInvalidate (RibOut *ribout)
 
void UpdateRibOut (RibOut *ribout, int queue_id)
 
void UpdatePeer (IPeerUpdate *peer)
 
bool UpdatePeerQueue (IPeerUpdate *peer, PeerState *ps, int queue_id)
 
void BuildSyncBitSet (const RibOut *ribout, RibState *rs, RibPeerSet *msync)
 
void SetQueueActive (const RibOut *ribout, RibState *rs, int queue_id, const RibPeerSet &munsync)
 
void SetQueueActive (RibOut *ribout, int queue_id, IPeerUpdate *peer)
 
bool IsQueueActive (RibOut *ribout, int queue_id, IPeerUpdate *peer)
 
void SetSendBlocked (RibOut *ribout, int queue_id, const RibPeerSet &blocked)
 
void SetSendBlocked (const RibOut *ribout, RibState *rs, int queue_id, const RibPeerSet &blocked)
 
void SetQueueSync (PeerState *ps, int queue_id)
 
 DISALLOW_COPY_AND_ASSIGN (BgpSenderPartition)
 

Private Attributes

BgpUpdateSendersender_
 
int index_
 
bool running_
 
bool disabled_
 
WorkQueue work_queue_
 
Workerworker_task_
 
PeerStateMap peer_state_imap_
 
RibStateMap rib_state_imap_
 

Friends

class BgpUpdateSenderTest
 
class RibOutUpdatesTest
 

Detailed Description

Definition at line 48 of file bgp_update_sender.h.

Member Typedef Documentation

Definition at line 108 of file bgp_update_sender.h.

Definition at line 109 of file bgp_update_sender.h.

typedef boost::ptr_list<WorkBase> BgpSenderPartition::WorkQueue
private

Definition at line 105 of file bgp_update_sender.h.

Constructor & Destructor Documentation

BgpSenderPartition::BgpSenderPartition ( BgpUpdateSender sender,
int  index 
)

Definition at line 413 of file bgp_update_sender.cc.

BgpSenderPartition::~BgpSenderPartition ( )

Definition at line 421 of file bgp_update_sender.cc.

Here is the call graph for this function:

Member Function Documentation

void BgpSenderPartition::Add ( RibOut ribout,
IPeerUpdate peer 
)

Definition at line 439 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::BuildSyncBitSet ( const RibOut ribout,
RibState rs,
RibPeerSet msync 
)
private

Definition at line 648 of file bgp_update_sender.cc.

Here is the call graph for this function:

bool BgpSenderPartition::CheckInvariants ( ) const

Definition at line 913 of file bgp_update_sender.cc.

Here is the call graph for this function:

BgpSenderPartition::DISALLOW_COPY_AND_ASSIGN ( BgpSenderPartition  )
private
int BgpSenderPartition::index ( ) const
inline

Definition at line 66 of file bgp_update_sender.h.

bool BgpSenderPartition::IsQueueActive ( RibOut ribout,
int  queue_id,
IPeerUpdate peer 
)
private

Definition at line 746 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::MaybeStartWorker ( )
private

Definition at line 537 of file bgp_update_sender.cc.

Here is the call graph for this function:

bool BgpSenderPartition::PeerInSync ( IPeerUpdate peer) const

Definition at line 526 of file bgp_update_sender.cc.

Here is the call graph for this function:

bool BgpSenderPartition::PeerIsRegistered ( IPeerUpdate peer) const

Definition at line 517 of file bgp_update_sender.cc.

Here is the call graph for this function:

bool BgpSenderPartition::PeerIsSendReady ( IPeerUpdate peer) const

Definition at line 507 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::PeerSendReady ( IPeerUpdate peer)

Definition at line 485 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::Remove ( RibOut ribout,
IPeerUpdate peer 
)

Definition at line 453 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::RibOutActive ( RibOut ribout,
int  queue_id 
)

Definition at line 476 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::set_disabled ( bool  disabled)

Definition at line 580 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::SetQueueActive ( const RibOut ribout,
RibState rs,
int  queue_id,
const RibPeerSet munsync 
)
private

Definition at line 709 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::SetQueueActive ( RibOut ribout,
int  queue_id,
IPeerUpdate peer 
)
private

Definition at line 729 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::SetQueueSync ( PeerState ps,
int  queue_id 
)
private

Definition at line 761 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::SetSendBlocked ( RibOut ribout,
int  queue_id,
const RibPeerSet blocked 
)
private

Definition at line 694 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::SetSendBlocked ( const RibOut ribout,
RibState rs,
int  queue_id,
const RibPeerSet blocked 
)
private

Definition at line 676 of file bgp_update_sender.cc.

Here is the call graph for this function:

int BgpSenderPartition::task_id ( ) const

Definition at line 430 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::UpdatePeer ( IPeerUpdate peer)
private

Definition at line 862 of file bgp_update_sender.cc.

Here is the call graph for this function:

bool BgpSenderPartition::UpdatePeerQueue ( IPeerUpdate peer,
PeerState ps,
int  queue_id 
)
private

Definition at line 818 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::UpdateRibOut ( RibOut ribout,
int  queue_id 
)
private

Definition at line 779 of file bgp_update_sender.cc.

Here is the call graph for this function:

unique_ptr< BgpSenderPartition::WorkBase > BgpSenderPartition::WorkDequeue ( )
private

Definition at line 551 of file bgp_update_sender.cc.

void BgpSenderPartition::WorkEnqueue ( WorkBase wentry)
private

Definition at line 568 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::WorkPeerEnqueue ( IPeerUpdate peer)
private

Definition at line 588 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::WorkPeerInvalidate ( IPeerUpdate peer)
private

Definition at line 599 of file bgp_update_sender.cc.

void BgpSenderPartition::WorkRibOutEnqueue ( RibOut ribout,
int  queue_id 
)
private

Definition at line 617 of file bgp_update_sender.cc.

Here is the call graph for this function:

void BgpSenderPartition::WorkRibOutInvalidate ( RibOut ribout)
private

Definition at line 628 of file bgp_update_sender.cc.

Friends And Related Function Documentation

friend class BgpUpdateSenderTest
friend

Definition at line 72 of file bgp_update_sender.h.

friend class RibOutUpdatesTest
friend

Definition at line 73 of file bgp_update_sender.h.

Member Data Documentation

bool BgpSenderPartition::disabled_
private

Definition at line 139 of file bgp_update_sender.h.

int BgpSenderPartition::index_
private

Definition at line 137 of file bgp_update_sender.h.

PeerStateMap BgpSenderPartition::peer_state_imap_
private

Definition at line 142 of file bgp_update_sender.h.

RibStateMap BgpSenderPartition::rib_state_imap_
private

Definition at line 143 of file bgp_update_sender.h.

bool BgpSenderPartition::running_
private

Definition at line 138 of file bgp_update_sender.h.

BgpUpdateSender* BgpSenderPartition::sender_
private

Definition at line 136 of file bgp_update_sender.h.

WorkQueue BgpSenderPartition::work_queue_
private

Definition at line 140 of file bgp_update_sender.h.

Worker* BgpSenderPartition::worker_task_
private

Definition at line 141 of file bgp_update_sender.h.


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