mirror of
https://github.com/retspen/webvirtcloud
synced 2024-12-25 07:35:22 +00:00
Fix bug with err instead of True in connection_manager.host_is_up, which
lead to freeze in panel if compute is down
This commit is contained in:
parent
e601c23b4a
commit
edd4887a2d
1 changed files with 3 additions and 2 deletions
|
@ -928,7 +928,7 @@ def get_host_instances(request, comp):
|
||||||
all_host_vms = {}
|
all_host_vms = {}
|
||||||
status = connection_manager.host_is_up(comp.type, comp.hostname)
|
status = connection_manager.host_is_up(comp.type, comp.hostname)
|
||||||
|
|
||||||
if status:
|
if status is True:
|
||||||
conn = wvmHostDetails(comp, comp.login, comp.password, comp.type)
|
conn = wvmHostDetails(comp, comp.login, comp.password, comp.type)
|
||||||
comp_node_info = conn.get_node_info()
|
comp_node_info = conn.get_node_info()
|
||||||
comp_mem = conn.get_memory_usage()
|
comp_mem = conn.get_memory_usage()
|
||||||
|
@ -949,7 +949,8 @@ def get_host_instances(request, comp):
|
||||||
refresh_instance_database(comp_info, vm, info)
|
refresh_instance_database(comp_info, vm, info)
|
||||||
|
|
||||||
conn.close()
|
conn.close()
|
||||||
|
else:
|
||||||
|
raise libvirtError("Problem occured with {} - {}".format(comp.name, status))
|
||||||
return all_host_vms
|
return all_host_vms
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue