restore filter to router listing
Filter when given a list of router ids. Change-Id: I68db050a0de8b26ac1fcd6a018690c0e32554677
This commit is contained in:
parent
6dc4874125
commit
241f1a266b
@ -55,10 +55,18 @@ class OVSNeutronPluginV2(ovs_neutron_plugin.OVSNeutronPluginV2):
|
|||||||
def list_active_sync_routers_on_active_l3_agent(
|
def list_active_sync_routers_on_active_l3_agent(
|
||||||
self, context, host, router_ids):
|
self, context, host, router_ids):
|
||||||
# Override L3AgentSchedulerDbMixin method
|
# Override L3AgentSchedulerDbMixin method
|
||||||
routers = self.get_routers(context)
|
|
||||||
router_ids = [r['id'] for r in routers]
|
|
||||||
if router_ids:
|
if router_ids:
|
||||||
return self.get_sync_data(context, router_ids=router_ids,
|
routers = self.get_routers(
|
||||||
active=True)
|
context,
|
||||||
|
filters={'id': router_ids},
|
||||||
|
)
|
||||||
else:
|
else:
|
||||||
return []
|
routers = self.get_routers(context)
|
||||||
|
new_router_ids = [r['id'] for r in routers]
|
||||||
|
if new_router_ids:
|
||||||
|
return self.get_sync_data(
|
||||||
|
context,
|
||||||
|
router_ids=new_router_ids,
|
||||||
|
active=True,
|
||||||
|
)
|
||||||
|
return []
|
||||||
|
Loading…
x
Reference in New Issue
Block a user