[openstack-dev] [ironic] support for various glance image reference formats - do we need them all?

Pavlo Shchelokovskyy pshchelokovskyy at mirantis.com
Mon Aug 7 12:47:06 UTC 2017


Hi all,

currently our GlanceImageService seems to support several ways of defining
a reference to glance image:

1) simple image UUID [0]
2) image UUID prefixed with 'glance://' protocol [1] (well, actually
anything starting with 'glance://' and ending with '/<uuid>')
3) full REST path to the image (as in
http://<glance-api>/v2/images/<image-uuid>),
also used to extract the glance API address [2]

Support for #3 must surely be removed, as we are moving to API endpoint
discovery from keystone catalog.
Besides I am pretty sure this code path can not actually be reached
currently, as the 'is_glance_image' will ignore such image refs and return
False for those [3], and 'get_image_service' would also not return the
GlanceImageService instance for such image refs [4].
Hence the question - if it is unusable anyway now, should we execute the
standard deprecation process when removing support for it or just remove
right away?

As for the #1 and #2 I do not see any big difference between those, and
proposed deprecating and eventually removing support for #2 ('glance://'
scheme) as part of [5]. Two people in review already raised a concern about
removing such support.

Thus I'd like to ask a broader audience - do we need support for glance
image references in 'glance://*<UUID>' form? Is it actually used somewhere?
What are the benefits of having it besides simple UUID?

[0]
http://git.openstack.org/cgit/openstack/ironic/tree/ironic/common/glance_service/service_utils.py#n149
[1]
http://git.openstack.org/cgit/openstack/ironic/tree/ironic/common/glance_service/service_utils.py#n155
[2]
http://git.openstack.org/cgit/openstack/ironic/tree/ironic/common/glance_service/service_utils.py#n160
[3]
http://git.openstack.org/cgit/openstack/ironic/tree/ironic/common/glance_service/service_utils.py#n208
[4]
http://git.openstack.org/cgit/openstack/ironic/tree/ironic/common/image_service.py#n267
[5] https://review.openstack.org/#/c/467728

Cheers,

-- 
Dr. Pavlo Shchelokovskyy
Senior Software Engineer
Mirantis Inc
www.mirantis.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20170807/372d101c/attachment.html>


More information about the OpenStack-dev mailing list