glance.db.utils module

glance.db.utils.ensure_image_dict_v2_compliant(image)[source]

Accepts an image dictionary that contains a v1-style ‘is_public’ member and returns the equivalent v2-style image dictionary.

glance.db.utils.is_image_visible(context, image, image_member_find, status=None)[source]

Return True if the image is visible in this context.

glance.db.utils.mutate_image_dict_to_v1(image)[source]

Replaces a v2-style image dictionary’s ‘visibility’ member with the equivalent v1-style ‘is_public’ member.