]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Log RPC initialization in L3 service plugin and ML2
authorAssaf Muller <amuller@redhat.com>
Wed, 8 Apr 2015 23:13:14 +0000 (19:13 -0400)
committerAssaf Muller <amuller@redhat.com>
Mon, 13 Apr 2015 22:36:22 +0000 (18:36 -0400)
Under certain conditions the messaging server may be up but
not responding. In this case the Neutron server will fail to start
silently, making it pretty hard to track down the issue without
looking through a lot of code and adding a bunch of random logging.

Change-Id: I6a562476f2789386a020db7b21b9349c4c58c30c

neutron/plugins/ml2/plugin.py
neutron/services/l3_router/l3_router_plugin.py

index 3f734d9e315cef368c65ef20378cfd1ae17b80d2..240f3b03cb5fff247d9f79dafe80bef011cd84f3 100644 (file)
@@ -41,6 +41,7 @@ from neutron.callbacks import resources
 from neutron.common import constants as const
 from neutron.common import exceptions as exc
 from neutron.common import ipv6_utils
+from neutron.common import log as neutron_log
 from neutron.common import rpc as n_rpc
 from neutron.common import topics
 from neutron.common import utils
@@ -156,6 +157,7 @@ class Ml2Plugin(db_base_plugin_v2.NeutronDbPluginV2,
             dhcp_rpc_agent_api.DhcpAgentNotifyAPI()
         )
 
+    @neutron_log.log
     def start_rpc_listeners(self):
         self.endpoints = [rpc.RpcCallbacks(self.notifier, self.type_manager),
                           securitygroups_rpc.SecurityGroupServerRpcCallback(),
index 2b35e9b329e97e37a643c6e37d45e3216d79afd2..32c30bd47647cf866d935320db97ff7028da277e 100644 (file)
@@ -19,6 +19,7 @@ from oslo_utils import importutils
 from neutron.api.rpc.agentnotifiers import l3_rpc_agent_api
 from neutron.api.rpc.handlers import l3_rpc
 from neutron.common import constants as q_const
+from neutron.common import log as neutron_log
 from neutron.common import rpc as n_rpc
 from neutron.common import topics
 from neutron.db import common_db_mixin
@@ -61,6 +62,7 @@ class L3RouterPlugin(common_db_mixin.CommonDbMixin,
             l3_dvrscheduler_db.subscribe()
         l3_db.subscribe()
 
+    @neutron_log.log
     def setup_rpc(self):
         # RPC support
         self.topic = topics.L3PLUGIN