Treat cpu as float (not integer)

Change-Id: I288f833b69693dc36934549a13123415a71e1578
Closes-Bug: #1860937
This commit is contained in:
Hongbin Lu 2020-01-26 21:11:11 +00:00
parent 428f9f8375
commit 948af86c41

View File

@ -371,7 +371,7 @@ class ContainerBase(base.ZunPersistentObject, base.ZunObject):
- disk: The sum of container's disk size.
"""
usage = dbapi.count_usage(context, cls.container_type, project_id,
flag)[0] or 0
flag)[0] or 0.0
return usage