public interface ImageService extends RestService
Modifier and Type | Method and Description |
---|---|
boolean |
addMember(String imageId,
String tenantId)
Authorize a tenant to access a private image
|
boolean |
addMember(String imageId,
String tenantId,
boolean canShare)
Authorize a tenant to access a private image
|
Image |
create(Image image,
Payload<?> payload)
Creates a new Image
|
ActionResponse |
delete(String imageId)
Deletes an Image by ID
|
Image |
get(String imageId)
Gets an Image by ID
|
InputStream |
getAsStream(String imageId)
Return the image date for the image by ID
|
List<? extends Image> |
list()
Lists public VM images by the default page size defined by openstack
|
List<? extends Image> |
list(Map<String,String> filteringParams)
* Returns list of public VM images filtered by parameters.
|
List<? extends Image> |
listAll()
Lists all public VM images
|
List<? extends Image> |
listAll(Map<String,String> filteringParams)
* Returns list of public VM images filtered by parameters when the result greater than the default page size defined by openstack
|
List<? extends ImageMember> |
listMembers(String imageId)
List of the other system tenants that may access a given virtual machine image that the Glance server knows about.
|
boolean |
removeMember(String imageId,
String tenantId)
Revoke a tenant's right to access a private image.
|
Image |
reserve(Image image)
Reserves a new image to be uploaded later.
|
Image |
update(Image image)
Updates an Image.
|
Image |
upload(String imageId,
Payload<?> payload,
Image image)
Upload image data for a previously-reserved image
If an image was previously reserved, and thus is in the queued state, then image data can be added using this method. |
List<? extends Image> list()
List<? extends Image> list(Map<String,String> filteringParams)
filteringParams
- map (name, value) of filtering parametersList<? extends Image> listAll(Map<String,String> filteringParams)
filteringParams
- map (name, value) of filtering parametersImage get(String imageId)
imageId
- the image identifierActionResponse delete(String imageId)
imageId
- the image identifierImage update(Image image)
image
- the image to updateInputStream getAsStream(String imageId)
imageId
- the image identifierImage create(Image image, Payload<?> payload)
image
- the image to createpayload
- the payload (image data to upload). Note: if the payload is null then reserve(Image)
will be called internallyImage reserve(Image image)
upload(String, Payload, Image)
image
- the image to reserveImage upload(String imageId, Payload<?> payload, @Nullable Image image)
imageId
- the image identifier of the previously reserved imagepayload
- the playload to uploadimage
- the optional Image which will be used to update meta data during this transactionList<? extends ImageMember> listMembers(String imageId)
imageId
- the image identiferboolean addMember(String imageId, String tenantId)
imageId
- the image identifiertenantId
- the tenantboolean addMember(String imageId, String tenantId, boolean canShare)
imageId
- the image identifiertenantId
- the tenantcanShare
- both existing and new memberships will have `can_share` set to the provided valueCopyright © 2017. All rights reserved.