From 284941a064b90b0d96391cb085d8e2af05428eba Mon Sep 17 00:00:00 2001 From: Ted Ghose Date: Tue, 5 May 2015 11:08:38 -0700 Subject: [PATCH] VRouters not showing up in UI(double commit) Change-Id: I244e81aaa6996f9fccf52610f7526a12dea83842 Partial-Fix: #1432072 --- .../contrail-topology/contrail_topology/controller.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/analytics/contrail-topology/contrail_topology/controller.py b/src/analytics/contrail-topology/contrail_topology/controller.py index aa908cd5033..fc94e9fc897 100644 --- a/src/analytics/contrail-topology/contrail_topology/controller.py +++ b/src/analytics/contrail-topology/contrail_topology/controller.py @@ -39,8 +39,12 @@ def get_vrouters(self): self.vrouter_macs = {} for vr in self.analytic_api.list_vrouters(): d = self.analytic_api.get_vrouter(vr, 'VrouterAgent:phy_if') - d.update(self.analytic_api.get_vrouter(vr, - 'VrouterAgent:self_ip_list')) + if 'VrouterAgent' not in d: + d['VrouterAgent'] = {} + _ipl = self.analytic_api.get_vrouter(vr, + 'VrouterAgent:self_ip_list') + if 'VrouterAgent' in _ipl: + d['VrouterAgent'].update(_ipl['VrouterAgent']) if 'VrouterAgent' not in d or\ 'self_ip_list' not in d['VrouterAgent'] or\ 'phy_if' not in d['VrouterAgent']: