Merge "Big Switch: Add missing data to topology sync"
This commit is contained in:
commit
eced2dafe4
@ -179,11 +179,13 @@ class NeutronRestProxyV2Base(db_base_plugin_v2.NeutronDbPluginV2,
|
|||||||
get_routers=True):
|
get_routers=True):
|
||||||
admin_context = qcontext.get_admin_context()
|
admin_context = qcontext.get_admin_context()
|
||||||
networks = []
|
networks = []
|
||||||
|
# this method is used by the ML2 driver so it can't directly invoke
|
||||||
all_networks = self.get_networks(admin_context) or []
|
# the self.get_(ports|networks) methods
|
||||||
|
plugin = manager.NeutronManager.get_plugin()
|
||||||
|
all_networks = plugin.get_networks(admin_context) or []
|
||||||
for net in all_networks:
|
for net in all_networks:
|
||||||
mapped_network = self._get_mapped_network_with_subnets(net)
|
mapped_network = self._get_mapped_network_with_subnets(net)
|
||||||
flips_n_ports = {}
|
flips_n_ports = mapped_network
|
||||||
if get_floating_ips:
|
if get_floating_ips:
|
||||||
flips_n_ports = self._get_network_with_floatingips(
|
flips_n_ports = self._get_network_with_floatingips(
|
||||||
mapped_network)
|
mapped_network)
|
||||||
@ -191,8 +193,8 @@ class NeutronRestProxyV2Base(db_base_plugin_v2.NeutronDbPluginV2,
|
|||||||
if get_ports:
|
if get_ports:
|
||||||
ports = []
|
ports = []
|
||||||
net_filter = {'network_id': [net.get('id')]}
|
net_filter = {'network_id': [net.get('id')]}
|
||||||
net_ports = self.get_ports(admin_context,
|
net_ports = plugin.get_ports(admin_context,
|
||||||
filters=net_filter) or []
|
filters=net_filter) or []
|
||||||
for port in net_ports:
|
for port in net_ports:
|
||||||
mapped_port = self._map_state_and_status(port)
|
mapped_port = self._map_state_and_status(port)
|
||||||
mapped_port['attachment'] = {
|
mapped_port['attachment'] = {
|
||||||
|
Loading…
Reference in New Issue
Block a user