Fix reconnecting to libvirt.
The right logic was in place for dealing with losing a connection to libvirt and reconnecting. However, it was observed that we actually get VIR_ERR_INTERNAL_ERROR, VIR_FROM_RPC after restarting libvirtd. The code is just updated to deal with INTERNAL_ERROR. Fix bug 1154473. Change-Id: Idf4abf3fe485cf534f1732e4340fc35652fec003
This commit is contained in:
@@ -2864,7 +2864,8 @@ class LibvirtConnTestCase(test.TestCase):
|
||||
def test_broken_connection(self):
|
||||
for (error, domain) in (
|
||||
(libvirt.VIR_ERR_SYSTEM_ERROR, libvirt.VIR_FROM_REMOTE),
|
||||
(libvirt.VIR_ERR_SYSTEM_ERROR, libvirt.VIR_FROM_RPC)):
|
||||
(libvirt.VIR_ERR_SYSTEM_ERROR, libvirt.VIR_FROM_RPC),
|
||||
(libvirt.VIR_ERR_INTERNAL_ERROR, libvirt.VIR_FROM_RPC)):
|
||||
|
||||
conn = libvirt_driver.LibvirtDriver(fake.FakeVirtAPI(), False)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user