v2 API: Not possible to "retire" disk formats
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance Client |
Fix Released
|
Undecided
|
Nicolas Simonds |
Bug Description
Use case:
We tried to remove QCOW2 from the list of supported disk_formats in some of our deployments, because the conversion overhead of using them was making for a sub-wonderful user experience.
After removing "qcow2" from the disk_formats parameter, the Glance v2 API started returning 404 errors on extant QCOW2 images. This means that we effectively cannot "retire" this disk format and block new image uploads, since Glance will immediately disavow all knowledge of any QCOW2 images in its purview.
Steps to Reproduce:
1. Stand up a devstack
2. Upload a QCOW2 image
3. glance --os-image-
4. Reconfigure glance-api to only allow e.g., "raw" disk_formats:
5. Restart glance-api
6. glance --os-image-
Expected results:
The "glance image-show" command works both times
Actual results:
The second "glance image-show" command fails.
Errata:
The "glance image-show" using the v1 API does work as expected.
Changed in glance: | |
assignee: | nobody → Kairat Kushaev (kkushaev) |
Changed in python-glanceclient: | |
assignee: | Kairat Kushaev (kkushaev) → nobody |
Changed in python-glanceclient: | |
assignee: | nobody → Nicolas Simonds (nicolas.simonds) |
So this behavior happens when glanceclient already received image information. You can at least get an info trhough API as workaround.
The root cause is in schema validation after receiving this info. Need to think more about this case.