Skip to content

Commit

Permalink
Merge "Issue: ----- if the first partition is empty, There is no furt…
Browse files Browse the repository at this point in the history
…her partitions are getting processed. Fix: ---- look if the parttion is empty walk through the parttions to get the first location of the entry and proceed further." into R3.0
  • Loading branch information
Zuul authored and opencontrail-ci-admin committed May 1, 2016
2 parents 6cd1b67 + 164f920 commit 1670281
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/vnsw/agent/pkt/pkt_sandesh_flow.cc
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,12 @@ bool PktSandeshFlow::Run() {
return true;
}

while (it == flow_obj->flow_entry_map_.end() &&
++partition_id_ < agent_->flow_thread_count()) {
flow_obj = agent_->pkt()->flow_table(partition_id_);
it = flow_obj->flow_entry_map_.begin();
}

while (it != flow_obj->flow_entry_map_.end()) {
FlowEntry *fe = it->second;
FlowStatsCollector *fec = fe->fsc();
Expand Down Expand Up @@ -505,6 +511,12 @@ bool PktSandeshFlowStats::Run() {
return true;
}

while (it == flow_obj->flow_entry_map_.end() &&
++partition_id_ < agent_->flow_thread_count()) {
flow_obj = agent_->pkt()->flow_table(partition_id_);
it = flow_obj->flow_entry_map_.begin();
}

while (it != flow_obj->flow_entry_map_.end()) {
FlowEntry *fe = it->second;
const FlowExportInfo *info = fsc->FindFlowExportInfo(fe);
Expand Down

0 comments on commit 1670281

Please sign in to comment.