Skip to content

Commit

Permalink
Display of RD in VrfIntrospect
Browse files Browse the repository at this point in the history
There is a supportability request to display route-distinguisher
assigned to each vrf on a compute node. Added RD field to vrfSandeshData
to display the same.

Change-Id: I2b2875008b4fe22d1ac3dcbe1e4f50094d5d96e2
Closes-bug: #1600255
  • Loading branch information
ravi-bk committed Aug 5, 2016
1 parent 64bc62a commit b68ea94
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/vnsw/agent/oper/agent.sandesh
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,7 @@ struct VrfSandeshData {
9: i32 vxlan_id; // VRF Label used for the VRF
10: i32 evpnindex (link="EvpnRouteReq"); // VRF Index evpn Table
11: i32 brindex (link="BridgeRouteReq"); // VRF Index L2 Table
12: string RD; // Route-Distinguisher
}

/**
Expand Down
4 changes: 4 additions & 0 deletions src/vnsw/agent/oper/vrf.cc
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,10 @@ bool VrfEntry::DBEntrySandesh(Sandesh *sresp, std::string &name) const {
data.set_vn("N/A");
}
data.set_table_label(table_label());
VrfTable *table = static_cast<VrfTable *>(get_table());
stringstream rd;
rd << table->agent()->compute_node_ip().to_string() << ":" << vrf_id();
data.set_RD(rd.str());

std::vector<VrfSandeshData> &list =
const_cast<std::vector<VrfSandeshData>&>(resp->get_vrf_list());
Expand Down

0 comments on commit b68ea94

Please sign in to comment.