]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Drop RpcProxy usage from neutron.agent.rpc.PluginApi
authorRussell Bryant <rbryant@redhat.com>
Fri, 14 Nov 2014 14:21:05 +0000 (14:21 +0000)
committerRussell Bryant <rbryant@redhat.com>
Wed, 19 Nov 2014 17:18:34 +0000 (17:18 +0000)
commit8098b6bd20bb12520e438ef9125dc7b96664f712
treed7631b0a2fa4aa9de2b4a96513213b9f6ebc8a3b
parentab40ef64063b19739b8558feaee828f71e91eb56
Drop RpcProxy usage from neutron.agent.rpc.PluginApi

This patch removes the usage of the RpcProxy compatibility class from
the neutron.agent.rpc.PluginApi class.  The equivalent use of
oslo.messaging APIs have been put in place instead.  This simple
conversion had a pretty wide impact on unit tests, as well.

The security groups API was converted in this patch as well.  It was
necessary because the security group class is used as a mixin, so it
must be implemented the same way.  Unfortunately, the way this is used
as a mix-in is not consistent, so for now it's only conditionally
converted.

Finally, some other miscellaneous plugin specific interfaces were
converted as well.  Again, these were methods mixed-in for certain
plugins.

Note that there's one very minor functional difference in this patch.
The previous code set the base version to be '1.1'.  The right pattern
is for this to be set to '1.0'.  This version is the default version
specified by the client, telling the server that it must implement at
least this version to satisfy the request.  The default should be
'1.0' and methods that require higher than that should specify it.
From looking at other parts of the code, '1.0' vs '1.1' is not
actually important, as '1.1' was actually the addition of some
security group methods defined elsewhere.  The correction is more
about establishing the right pattern to follow.

Change-Id: I391c01e79943ef179d815ea602253720925ccce1
neutron/agent/rpc.py
neutron/agent/securitygroups_rpc.py
neutron/plugins/nec/agent/nec_neutron_agent.py
neutron/plugins/ryu/agent/ryu_neutron_agent.py
neutron/tests/unit/hyperv/test_hyperv_rpcapi.py
neutron/tests/unit/ml2/test_rpcapi.py
neutron/tests/unit/mlnx/test_rpcapi.py
neutron/tests/unit/nec/test_nec_agent.py
neutron/tests/unit/ryu/test_ryu_agent.py
neutron/tests/unit/test_agent_rpc.py
neutron/tests/unit/test_security_groups_rpc.py