resolve ResourceProviderSyncFailed issue
This is caused by the "/" operation difference between python 2.x and python 3.x
In python 2.x "/" int / int returns int while
in python 3.x int / int return the real result.
Closes-Bug: #1893864
Change-Id: I1aa96bdc2fdb2ca856b73b91e3120c75ec104537
(cherry picked from commit 73aad31a34
)
This commit is contained in:
parent
1c28a88afd
commit
f5f184ea1b
|
@ -88,8 +88,8 @@ class VCState(object):
|
|||
return data
|
||||
|
||||
data["vcpus"] = stats['cpu']['vcpus']
|
||||
data["disk_total"] = capacity / units.Gi
|
||||
data["disk_available"] = freespace / units.Gi
|
||||
data["disk_total"] = capacity // units.Gi
|
||||
data["disk_available"] = freespace // units.Gi
|
||||
data["disk_used"] = data["disk_total"] - data["disk_available"]
|
||||
data["host_memory_total"] = stats['mem']['total']
|
||||
data["host_memory_free"] = stats['mem']['free']
|
||||
|
|
Loading…
Reference in New Issue