Merge "[Pure Storge] Ensure correct provisioned space value is used"

This commit is contained in:
Zuul 2025-03-08 04:37:03 +00:00 committed by Gerrit Code Review
commit e9396dc63c
2 changed files with 16 additions and 2 deletions

View File

@ -1086,8 +1086,15 @@ class PureBaseVolumeDriver(san.SanDriver):
total_capacity = float(space_info.capacity) / units.Gi
used_space = float(space_info.space.total_physical) / units.Gi
free_space = float(total_capacity - used_space)
provisioned_space = float(space_info.space.
total_provisioned) / units.Gi
# If array uses Evergreen/One model then total_provisioned
# is not reported so use the closest value avaible in that
# consumption model
try:
provisioned_space = float(space_info.space.
total_provisioned) / units.Gi
except AttributeError:
provisioned_space = float(space_info.space.
used_provisioned) / units.Gi
total_reduction = float(space_info.space.total_reduction)
total_vols = len(volumes)
total_hosts = len(hosts)

View File

@ -0,0 +1,7 @@
---
fixes:
- |
`Bug #2090310 <https://bugs.launchpad.net/cinder/+bug/2090310>`_:
[Pure Storage] Fixed issue with FlashArray using the Evergreen//One
consumption model not reporting ``total_provisioned``. Used
``used_provisoned`` instead in this case.