@log.log
def get_dvr_mac_address_by_host(self, context, host):
- return self.call(context,
- self.make_msg('get_dvr_mac_address_by_host',
- host=host),
- version=self.DVR_RPC_VERSION)
+ cctxt = self.client.prepare(version=self.DVR_RPC_VERSION)
+ return cctxt.call(context, 'get_dvr_mac_address_by_host', host=host)
@log.log
def get_dvr_mac_address_list(self, context):
- return self.call(context,
- self.make_msg('get_dvr_mac_address_list'),
- version=self.DVR_RPC_VERSION)
+ cctxt = self.client.prepare(version=self.DVR_RPC_VERSION)
+ return cctxt.call(context, 'get_dvr_mac_address_list')
@log.log
def get_ports_on_host_by_subnet(self, context, host, subnet):
- return self.call(context,
- self.make_msg(
- 'get_ports_on_host_by_subnet',
- host=host,
- subnet=subnet),
- version=self.DVR_RPC_VERSION)
+ cctxt = self.client.prepare(version=self.DVR_RPC_VERSION)
+ return cctxt.call(context, 'get_ports_on_host_by_subnet',
+ host=host, subnet=subnet)
@log.log
def get_subnet_for_dvr(self, context, subnet):
- return self.call(context,
- self.make_msg('get_subnet_for_dvr',
- subnet=subnet),
- version=self.DVR_RPC_VERSION)
+ cctxt = self.client.prepare(version=self.DVR_RPC_VERSION)
+ return cctxt.call(context, 'get_subnet_for_dvr', subnet=subnet)
class DVRServerRpcCallback(object):
def get_firewalls_for_tenant(self, context, **kwargs):
"""Get the Firewalls with rules from the Plugin to send to driver."""
LOG.debug("Retrieve Firewall with rules from Plugin")
-
- return self.call(context,
- self.make_msg('get_firewalls_for_tenant',
- host=self.host))
+ cctxt = self.client.prepare()
+ return cctxt.call(context, 'get_firewalls_for_tenant', host=self.host)
def get_tenants_with_firewalls(self, context, **kwargs):
"""Get all Tenants that have Firewalls configured from plugin."""
LOG.debug("Retrieve Tenants with Firewalls configured from Plugin")
-
- return self.call(context,
- self.make_msg('get_tenants_with_firewalls',
- host=self.host))
+ cctxt = self.client.prepare()
+ return cctxt.call(context,
+ 'get_tenants_with_firewalls', host=self.host)
class FWaaSL3AgentRpcCallback(api.FWaaSAgentRpcCallbackMixin):