]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Add versioned object serialize/deserialize for resources RPC
authorMoshe Levi <moshele@mellanox.com>
Thu, 9 Jul 2015 10:21:49 +0000 (13:21 +0300)
committerIhar Hrachyshka <ihrachys@redhat.com>
Sat, 25 Jul 2015 06:51:39 +0000 (08:51 +0200)
commitd2259240bb06f2e1d82465d3ddc0ee7073795087
tree1bc58a5ef5cbab9b40111b784243fdc8070a1d14
parent7ed1d4f61635e67d0a554ed34540a03222c3f9d3
Add versioned object serialize/deserialize for resources RPC

Also switched RPC callback API to consistently receive resource_type
string and not a resource class. This is because for get_info(), we
cannot propagate a class thru RPC but only a string that uniquely
identifies the class. So it would be not optimal to require the server
to discover the corresponding class from the type name passed from the
agent.

Also updated some comments in api/rpc/callbacks directory to reflect
that we handle NeutronObjects, not dicts.

Finally, killed the rule resource registration from QoS plugin and the
rule type from supported resources since it's YAGNI at least now.

Partially-Implements: blueprint quantum-qos-api
Change-Id: I5929338953a2ad7fa68312d79394a306eb0164a2
neutron/agent/l2/extensions/qos_agent.py
neutron/api/rpc/callbacks/registry.py
neutron/api/rpc/callbacks/resource_manager.py
neutron/api/rpc/callbacks/resources.py
neutron/api/rpc/handlers/resources_rpc.py
neutron/services/qos/qos_plugin.py
neutron/tests/unit/api/rpc/callbacks/test_resource_manager.py
neutron/tests/unit/api/rpc/callbacks/test_resources.py [new file with mode: 0644]
neutron/tests/unit/api/rpc/handlers/test_resources_rpc.py [new file with mode: 0755]