glance.api.v2.cached_images module
Controller for Image Cache Management API
-
class glance.api.v2.cached_images.CacheController(db_api=None, policy_enforcer=None, notifier=None, store_api=None)[source]
Bases: object
A controller for managing cached images.
-
clear_cache(req)[source]
DELETE /cache - Clear cache and queue
Removes all images from cache and queue.
-
delete_cache_entry(req, image_id)[source]
DELETE /cache/<IMAGE_ID> - Remove image from cache
Removes the image from cache or queue.
-
delete_cached_image(req, image_id)[source]
DELETE /cached_images/<IMAGE_ID>
Removes an image from the cache.
-
delete_cached_images(req)[source]
DELETE /cached_images - Clear all active cached images
Removes all images from the cache.
-
delete_queued_image(req, image_id)[source]
DELETE /queued_images/<IMAGE_ID>
Removes an image from the cache.
-
delete_queued_images(req)[source]
DELETE /queued_images - Clear all active queued images
Removes all images from the cache.
-
get_cache_state(req)[source]
GET /cache/ - Get currently cached and queued images
Returns dict of cached and queued images
-
get_cached_images(req)[source]
GET /cached_images
Returns a mapping of records about cached images.
-
get_queued_images(req)[source]
GET /queued_images
Returns a mapping of records about queued images.
-
image_exists_in_cache(image_id)[source]
-
queue_image(req, image_id)[source]
PUT /queued_images/<IMAGE_ID>
Queues an image for caching. We do not check to see if
the image is in the registry here. That is done by the
prefetcher…
-
queue_image_from_api(req, image_id)[source]
PUT /cache/<IMAGE_ID>
Queues an image for caching. We do not check to see if
the image is in the registry here. That is done by the
prefetcher…
-
class glance.api.v2.cached_images.CachedImageDeserializer[source]
Bases: glance.common.wsgi.JSONRequestDeserializer
-
class glance.api.v2.cached_images.CachedImageSerializer[source]
Bases: glance.common.wsgi.JSONResponseSerializer
-
glance.api.v2.cached_images.create_resource()[source]
Cached Images resource factory method