From 3f807dc989171e5991cb2181ba5a91fde5ecf349 Mon Sep 17 00:00:00 2001 From: Edan David Date: Mon, 22 May 2017 04:01:22 -0400 Subject: [PATCH] Fix deprecation warning Modules moved from 'neutron.agent.securitygroups_rpc' to 'neutron.api.rpc.handlers.securitygroups_rpc' Change-Id: I2a7cd993cee3b8adcbeb80ebae350655d9778889 --- .../ml2/drivers/mlnx/agent/mlnx_eswitch_neutron_agent.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/networking_mlnx/plugins/ml2/drivers/mlnx/agent/mlnx_eswitch_neutron_agent.py b/networking_mlnx/plugins/ml2/drivers/mlnx/agent/mlnx_eswitch_neutron_agent.py index 7f72413..37e2269 100644 --- a/networking_mlnx/plugins/ml2/drivers/mlnx/agent/mlnx_eswitch_neutron_agent.py +++ b/networking_mlnx/plugins/ml2/drivers/mlnx/agent/mlnx_eswitch_neutron_agent.py @@ -21,7 +21,8 @@ import time import eventlet eventlet.monkey_patch() from neutron.agent import rpc as agent_rpc -from neutron.agent import securitygroups_rpc as sg_rpc +from neutron.agent import securitygroups_rpc as agent_sg_rpc +from neutron.api.rpc.handlers import securitygroups_rpc as sg_rpc from neutron.common import config as common_config from neutron.common import topics from neutron.plugins.common import constants as p_const @@ -197,7 +198,7 @@ class MlnxEswitchNeutronAgent(object): self.context = context.get_admin_context_without_session() self.plugin_rpc = agent_rpc.PluginApi(topics.PLUGIN) self.sg_plugin_rpc = sg_rpc.SecurityGroupServerRpcApi(topics.PLUGIN) - self.sg_agent = sg_rpc.SecurityGroupAgentRpc(self.context, + self.sg_agent = agent_sg_rpc.SecurityGroupAgentRpc(self.context, self.sg_plugin_rpc) self._setup_rpc()