Merge "Clean imports in code"

This commit is contained in:
Jenkins 2016-08-17 14:56:46 +00:00 committed by Gerrit Code Review
commit b9169e34e3

View File

@ -15,14 +15,15 @@
from neutron_lib import constants
from neutron.agent.l3.dvr_edge_router import DvrEdgeRouter
from neutron.agent.l3 import dvr_edge_router
from neutron.agent.l3 import dvr_snat_ns
from neutron.agent.l3.ha_router import HaRouter
from neutron.agent.l3.router_info import RouterInfo
from neutron.agent.l3 import ha_router
from neutron.agent.l3 import router_info
from neutron.common import constants as l3_constants
class DvrEdgeHaRouter(DvrEdgeRouter, HaRouter):
class DvrEdgeHaRouter(dvr_edge_router.DvrEdgeRouter,
ha_router.HaRouter):
"""Router class which represents a centralized SNAT
DVR router with HA capabilities.
"""
@ -40,7 +41,7 @@ class DvrEdgeHaRouter(DvrEdgeRouter, HaRouter):
def internal_network_added(self, port):
# Call RouterInfo's internal_network_added (Plugs the port, adds IP)
RouterInfo.internal_network_added(self, port)
router_info.RouterInfo.internal_network_added(self, port)
for subnet in port['subnets']:
self._set_subnet_arp_info(subnet['id'])
@ -83,7 +84,8 @@ class DvrEdgeHaRouter(DvrEdgeRouter, HaRouter):
self._clear_vips(interface_name)
def external_gateway_updated(self, ex_gw_port, interface_name):
HaRouter.external_gateway_updated(self, ex_gw_port, interface_name)
ha_router.HaRouter.external_gateway_updated(self, ex_gw_port,
interface_name)
def initialize(self, process_monitor):
self._create_snat_namespace()
@ -95,7 +97,7 @@ class DvrEdgeHaRouter(DvrEdgeRouter, HaRouter):
self.enable_keepalived()
def get_router_cidrs(self, device):
return RouterInfo.get_router_cidrs(self, device)
return router_info.RouterInfo.get_router_cidrs(self, device)
def _external_gateway_added(self, ex_gw_port, interface_name,
ns_name, preserve_ips):