Open
Description
Describe the bug
If volume has io_limit_policy applied, on volume details we have:
"io_limit_policy": {
"id": "qp_2",
"name": "qp_2"
},
So for both 'id' and 'name' key, dictionary has 'id' value.
To Reproduce
Steps to reproduce the behavior:
- Set IO policy on volume
- Query volume details
- io_limit_policy dictionary has io_policy id in both 'id' and 'name' keys.
Expected behavior
io_limit_policy dictionary has io_policy name value under 'name' key.
Additional context
I suspect bug in:
volume.py line 971:
if obj_vol.io_limit_policy:
volume_details.update(
{'io_limit_policy': {'name': obj_vol.io_limit_policy.id,
'id': obj_vol.io_limit_policy.id}})