ironic.common.swift.
SwiftAPI
[source]¶Bases: object
API for communicating with Swift.
connection
= None¶Underlying Swift connection object.
create_object
(container, obj, filename, object_headers=None)[source]¶Uploads a given file to Swift.
Parameters: |
|
---|---|
Returns: | The Swift UUID of the object |
Raises: | SwiftOperationError, if any operation with Swift fails. |
delete_object
(container, obj)[source]¶Deletes the given Swift object.
Parameters: |
|
---|---|
Raises: | SwiftObjectNotFoundError, if object is not found in Swift. |
Raises: | SwiftOperationError, if operation with Swift fails. |
get_temp_url
(container, obj, timeout)[source]¶Returns the temp url for the given Swift object.
Parameters: |
|
---|---|
Returns: | The temp url for the object. |
Raises: | SwiftOperationError, if any operation with Swift fails. |
head_object
(container, obj)[source]¶Retrieves the information about the given Swift object.
Parameters: |
|
---|---|
Returns: | The information about the object as returned by Swift client’s head_object call. |
Raises: | SwiftOperationError, if operation with Swift fails. |
update_object_meta
(container, obj, object_headers)[source]¶Update the metadata of a given Swift object.
Parameters: |
|
---|---|
Raises: | SwiftOperationError, if operation with Swift fails. |
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.