5 #ifndef SRC_BGP_BGP_MULTICAST_H_
6 #define SRC_BGP_BGP_MULTICAST_H_
8 #include <boost/scoped_ptr.hpp>
240 std::vector<std::string> *encap)
const;
247 typedef std::set<McastForwarder *, McastForwarderCompare>
ForwarderSet;
269 if (lhs->
group().to_ulong() < rhs->
group().to_ulong()) {
272 if (lhs->
group().to_ulong() > rhs->
group().to_ulong()) {
275 if (lhs->
source().to_ulong() < rhs->
source().to_ulong()) {
278 if (lhs->
source().to_ulong() > rhs->
source().to_ulong()) {
331 std::vector<std::string> *encap)
const;
337 typedef std::set<McastSGEntry *, McastSGEntryCompare>
SGList;
429 Ip4Address *address, std::vector<std::string> *encap)
const;
boost::asio::ip::address_v4 Ip4Address
std::vector< McastForwarder * > McastForwarderList
void RemoveLink(McastForwarder *forwarder)
void AddGlobalOListElems(BgpOListSpec *olist_spec)
const LabelBlock * label_block() const
friend class BgpMulticastTest
void AddGlobalTreeRoute()
Ip4Address router_id() const
void DeleteGlobalTreeRoute()
McastForwarder(McastSGEntry *sg_entry, ErmVpnRoute *route)
void AddLink(McastForwarder *forwarder)
LabelBlockPtr label_block_
Ip4Address address() const
McastForwarder * FindLink(McastForwarder *forwarder)
DISALLOW_COPY_AND_ASSIGN(McastForwarder)
ErmVpnRoute * global_tree_route() const
std::vector< std::string > encap() const
ErmVpnRoute * global_tree_route_
McastForwarderList tree_links_
void AddLocalOListElems(BgpOListSpec *olist_spec)
const RouteDistinguisher & route_distinguisher() const
std::vector< std::string > encap_
bool Update(ErmVpnRoute *route)
std::string ToString() const
UpdateInfo * GetUpdateInfo(ErmVpnTable *table)
friend class BgpMulticastTest
WorkQueue< McastSGEntry * > work_queue_
McastManagerPartition(McastTreeManager *tree_manager, size_t part_id)
bool GetForestNodePMSI(ErmVpnRoute *rt, uint32_t *label, Ip4Address *address, std::vector< std::string > *encap) const
ErmVpnRoute * GetGlobalTreeRootRoute(const Ip4Address &source, const Ip4Address &group) const
void EnqueueSGEntry(McastSGEntry *sg_entry)
bool ProcessSGEntry(McastSGEntry *sg_entry)
McastSGEntry * LocateSGEntry(Ip4Address group, Ip4Address source)
DBTablePartBase * GetTablePartition()
void NotifyForestNode(const Ip4Address &source, const Ip4Address &group)
const RoutingInstance * routing_instance() const
McastSGEntry * FindSGEntry(const Ip4Address &group, const Ip4Address &source)
DISALLOW_COPY_AND_ASSIGN(McastManagerPartition)
McastTreeManager * tree_manager_
std::set< McastSGEntry *, McastSGEntryCompare > SGList
McastTreeManager * tree_manager() const
void AddForwarder(McastForwarder *forwarder)
std::vector< ForwarderSet * > forwarder_sets_
McastForwarder * forest_node_
friend class BgpMulticastTest
void set_tree_result_route(ErmVpnRoute *route)
Ip4Address source() const
std::string ToString() const
std::set< McastForwarder *, McastForwarderCompare > ForwarderSet
McastSGEntry(McastManagerPartition *partition, Ip4Address group, Ip4Address source)
void clear_on_work_queue()
ErmVpnRoute * local_tree_route_
std::vector< bool > update_needed_
void UpdateLocalTreeRoute()
bool IsForestNode(McastForwarder *forwarder)
void DeleteLocalTreeRoute()
bool GetForestNodePMSI(uint32_t *label, Ip4Address *address, std::vector< std::string > *encap) const
void clear_tree_result_route()
void DeleteForwarder(McastForwarder *forwarder)
McastManagerPartition * partition_
const ErmVpnRoute * tree_result_route() const
void UpdateRoutes(uint8_t level)
const RouteDistinguisher & GetSourceRd() const
bool IsTreeBuilder(uint8_t level) const
void ChangeForwarder(McastForwarder *forwarder)
ErmVpnRoute * tree_result_route_
DISALLOW_COPY_AND_ASSIGN(McastSGEntry)
McastManagerPartition * partition()
ErmVpnRoute * GetGlobalTreeRootRoute() const
McastManagerPartition * GetPartition(int part_id)
friend class BgpMulticastTest
const ErmVpnRoute * GetGlobalErmVpnTreeMvpnRoute() const
void RouteListener(DBTablePartBase *tpart, DBEntryBase *db_entry)
DBTablePartBase * GetTablePartition(size_t part_id)
const_iterator begin() const
void TreeResultListener(McastManagerPartition *partition, ErmVpnRoute *route)
const ErmVpnTable * table() const
LifetimeRef< McastTreeManager > table_delete_ref_
PartitionList partitions_
LifetimeActor * deleter()
void NotifyForestNode(int part_id, const Ip4Address &source, const Ip4Address &group)
void TreeNodeListener(McastManagerPartition *partition, ErmVpnRoute *route)
const_iterator end() const
virtual bool GetForestNodePMSI(ErmVpnRoute *rt, uint32_t *label, Ip4Address *address, std::vector< std::string > *encap) const
McastTreeManager(ErmVpnTable *table)
virtual UpdateInfo * GetUpdateInfo(ErmVpnRoute *route)
virtual void Initialize()
DISALLOW_COPY_AND_ASSIGN(McastTreeManager)
PartitionList::const_iterator const_iterator
virtual ErmVpnRoute * GetGlobalTreeRootRoute(const Ip4Address &source, const Ip4Address &group) const
virtual ~McastTreeManager()
boost::scoped_ptr< DeleteActor > deleter_
std::vector< McastManagerPartition * > PartitionList
boost::intrusive_ptr< LabelBlock > LabelBlockPtr
bool operator()(const McastForwarder *lhs, const McastForwarder *rhs) const
bool operator()(const McastSGEntry *lhs, const McastSGEntry *rhs) const