4 #ifndef __AGENT_FLOW_TABLE_MGMT_H__
5 #define __AGENT_FLOW_TABLE_MGMT_H__
7 #include <boost/scoped_ptr.hpp>
255 typedef std::map<FlowEntryPtr, FlowEntryInfo, FlowEntryRefCmp>
288 uint32_t oflow_bytes,
300 uint32_t *ingress_flow_count,
301 uint32_t *egress_flow_count);
303 uint64_t *aged, uint32_t *active_flows);
314 uint32_t source_port);
316 uint32_t source_port,
354 const std::string &ace_id);
356 const int last_count);
377 #define FLOW_TRACE(obj, ...)\
379 Flow##obj::TraceMsg(FlowTraceBuf, __FILE__, __LINE__, ##__VA_ARGS__);\
382 #endif // __AGENT_FLOW_TABLE_MGMT_H__
void UpdateFlowStats(FlowEntryPtr &flow, uint32_t bytes, uint32_t packets, uint32_t oflow_bytes, const boost::uuids::uuid &u)
void DeleteDBEntryEvent(const DBEntry *entry, uint32_t gen_id)
static void LogFlowUnlocked(FlowEntry *flow, const std::string &op)
void AddFlow(FlowEntryPtr &flow)
void EnqueueUveAddEvent(const FlowEntry *flow) const
bool DbClientHandler(const DBEntry *entry)
bool DBRequestHandler(FlowMgmtRequestPtr req)
static bool LogHandler(FlowMgmtRequestPtr req)
WorkQueue< FlowMgmtRequestPtr > FlowMgmtQueue
VnFlowMgmtTree vn_flow_mgmt_tree_
virtual ~FlowMgmtManager()
size_t FlowDBQueueLength()
void FreeDBEntryEvent(FlowEvent::Event event, FlowMgmtKey *key, uint32_t gen_id)
FlowMgmtQueue db_event_queue_
void DeleteFlowEntryInfo(FlowEntryPtr &flow)
static bool ProcessEvent(FlowMgmtRequest *req, FlowMgmtKey *key, FlowMgmtTree *tree)
BgpAsAServiceFlowMgmtKey * FindBgpAsAServiceInfo(FlowEntry *flow, BgpAsAServiceFlowMgmtKey &key)
const FlowMgmtQueue * log_queue() const
void NonOperEntryEvent(FlowEvent::Event event, FlowEntry *flow)
void DeleteFlowMgmtKey(FlowEntry *flow, FlowEntryInfo *info, FlowMgmtKey *key, FlowMgmtKeyNode *node)
boost::shared_ptr< FlowMgmtRequest > FlowMgmtRequestPtr
void ChangeDBEntryEvent(const DBEntry *entry, uint32_t gen_id)
void EnqueueFlowEvent(FlowEvent *event)
void AddEvent(FlowEntry *low)
void RetryVrfDeleteEvent(const VrfEntry *vrf)
void ControllerNotify(uint8_t index)
static void InitLogQueue(Agent *agent)
InterfaceFlowMgmtTree interface_flow_mgmt_tree_
FlowEntryInfo * FindFlowEntryInfo(const FlowEntryPtr &flow)
void DisableWorkQueue(bool disable)
InetRouteFlowMgmtTree * ip4_route_flow_mgmt_tree()
const FlowMgmtQueue * request_queue() const
void RouteNHChangeEvent(const DBEntry *entry, uint32_t gen_id)
void SetAceSandeshData(const AclDBEntry *acl, AclFlowCountResp &data, const std::string &ace_id)
void SetAclFlowSandeshData(const AclDBEntry *acl, AclFlowResp &data, const int last_count)
VrfFlowMgmtTree vrf_flow_mgmt_tree_
FlowEntryInfo * LocateFlowEntryInfo(FlowEntryPtr &flow)
std::map< FlowEntryPtr, FlowEntryInfo, FlowEntryRefCmp > FlowEntryTree
void FlowUpdateQueueDisable(bool val)
void MakeFlowMgmtKeyTree(FlowEntry *flow, FlowMgmtKeyTree *tree)
void BgpAsAServiceNotify(const boost::uuids::uuid &vm_uuid, uint32_t source_port)
size_t FlowUpdateQueueLength()
std::map< FlowMgmtKey *, FlowMgmtKeyNode *, FlowMgmtKeyCmp > FlowMgmtKeyTree
BridgeRouteFlowMgmtTree bridge_route_flow_mgmt_tree_
void AddFlowMgmtKey(FlowEntry *flow, FlowEntryInfo *info, FlowMgmtKey *key, FlowMgmtKey *old_key)
void RetryVrfDelete(uint32_t vrf_id)
static void ShutdownLogQueue()
bool HasVrfFlows(uint32_t vrf)
FlowMgmtManager(Agent *agent, uint16_t table_index)
void BgpAsAServiceHealthCheckNotify(const boost::uuids::uuid &vm_uuid, uint32_t source_port, const boost::uuids::uuid &hc_uuid, bool add)
void DeleteEvent(FlowEntry *flow, const RevFlowDepParams ¶ms)
void FlowStatsUpdateEvent(FlowEntry *flow, uint32_t bytes, uint32_t packets, uint32_t oflow_bytes, const boost::uuids::uuid &u)
void AddDBEntryEvent(const DBEntry *entry, uint32_t gen_id)
void DBEntryEvent(FlowEvent::Event event, FlowMgmtKey *key, FlowEntry *flow)
bool operator()(const FlowEntryPtr &l, const FlowEntryPtr &r)
void set_disable(bool disabled)
InetRouteFlowMgmtTree ip6_route_flow_mgmt_tree_
bool BgpAsAServiceRequestHandler(FlowMgmtRequest *req)
NhFlowMgmtTree nh_flow_mgmt_tree_
DISALLOW_COPY_AND_ASSIGN(FlowMgmtManager)
static FlowMgmtQueue * log_queue_
InetRouteFlowMgmtTree ip4_route_flow_mgmt_tree_
std::unique_ptr< FlowMgmtDbClient > flow_mgmt_dbclient_
void DeleteFlow(FlowEntryPtr &flow, const RevFlowDepParams &p)
FlowMgmtDbClient * flow_mgmt_dbclient() const
void VnFlowCounters(const VnEntry *vn, uint32_t *ingress_flow_count, uint32_t *egress_flow_count)
void InterfaceFlowCount(const Interface *itf, uint64_t *created, uint64_t *aged, uint32_t *active_flows)
bool RequestHandler(FlowMgmtRequestPtr req)
boost::scoped_ptr< BgpAsAServiceFlowMgmtTree > bgp_as_a_service_flow_mgmt_tree_[MAX_XMPP_SERVERS]
FlowMgmtQueue request_queue_
AclFlowMgmtTree acl_flow_mgmt_tree_
uint16_t table_index() const
void EnqueueUveDeleteEvent(const FlowEntry *flow) const
boost::intrusive_ptr< FlowEntry > FlowEntryPtr