Merge "Fixed error use retry_on_disconnect decorator" into stable/ocata
This commit is contained in:
commit
cd9673fcd7
|
@ -121,6 +121,10 @@ class InstanceDiscovery(plugin_base.DiscoveryBase):
|
|||
self._connection = libvirt_utils.get_libvirt_connection(self.conf)
|
||||
return self._connection
|
||||
|
||||
@connection.setter
|
||||
def connection(self, value):
|
||||
self._connection = value
|
||||
|
||||
def discover(self, manager, param=None):
|
||||
"""Discover resources to monitor."""
|
||||
if self.method != "libvirt_metadata":
|
||||
|
|
|
@ -44,6 +44,10 @@ class LibvirtInspector(virt_inspector.Inspector):
|
|||
self._connection = libvirt_utils.get_libvirt_connection(self.conf)
|
||||
return self._connection
|
||||
|
||||
@connection.setter
|
||||
def connection(self, value):
|
||||
self._connection = value
|
||||
|
||||
@libvirt_utils.retry_on_disconnect
|
||||
def _lookup_by_uuid(self, instance):
|
||||
instance_name = util.instance_name(instance)
|
||||
|
|
Loading…
Reference in New Issue