Merge "Move object storage account_client to lib interface"
This commit is contained in:
commit
bc876de52f
@ -0,0 +1,9 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- |
|
||||||
|
Define below object storage service clients as libraries.
|
||||||
|
Add new service clients to the library interface so the
|
||||||
|
other projects can use these modules as stable libraries
|
||||||
|
without any maintenance changes.
|
||||||
|
|
||||||
|
* account_client
|
@ -50,41 +50,20 @@ class AccountClient(rest_client.RestClient):
|
|||||||
return resp, body
|
return resp, body
|
||||||
|
|
||||||
def list_account_metadata(self):
|
def list_account_metadata(self):
|
||||||
"""HEAD on the storage URL
|
"""List all account metadata."""
|
||||||
|
|
||||||
Returns all account metadata headers
|
|
||||||
"""
|
|
||||||
resp, body = self.head('')
|
resp, body = self.head('')
|
||||||
self.expected_success(204, resp.status)
|
self.expected_success(204, resp.status)
|
||||||
return resp, body
|
return resp, body
|
||||||
|
|
||||||
def list_account_containers(self, params=None):
|
def list_account_containers(self, params=None):
|
||||||
"""GET on the (base) storage URL
|
"""List all containers for the account.
|
||||||
|
|
||||||
Given valid X-Auth-Token, returns a list of all containers for the
|
Given valid X-Auth-Token, returns a list of all containers for the
|
||||||
account.
|
account.
|
||||||
|
|
||||||
Optional Arguments:
|
For a full list of available parameters, please refer to the official
|
||||||
limit=[integer value N]
|
API reference:
|
||||||
Limits the number of results to at most N values
|
https://developer.openstack.org/api-ref/object-store/#show-account-details-and-list-containers
|
||||||
DEFAULT: 10,000
|
|
||||||
|
|
||||||
marker=[string value X]
|
|
||||||
Given string value X, return object names greater in value
|
|
||||||
than the specified marker.
|
|
||||||
DEFAULT: No Marker
|
|
||||||
|
|
||||||
prefix=[string value Y]
|
|
||||||
Given string value Y, return object names starting with that prefix
|
|
||||||
|
|
||||||
reverse=[boolean value Z]
|
|
||||||
Reverse the result order based on the boolean value Z
|
|
||||||
DEFAULT: False
|
|
||||||
|
|
||||||
format=[string value, either 'json' or 'xml']
|
|
||||||
Specify either json or xml to return the respective serialized
|
|
||||||
response.
|
|
||||||
DEFAULT: Python-List returned in response body
|
|
||||||
"""
|
"""
|
||||||
url = '?%s' % urllib.urlencode(params) if params else ''
|
url = '?%s' % urllib.urlencode(params) if params else ''
|
||||||
|
|
@ -12,11 +12,11 @@
|
|||||||
# License for the specific language governing permissions and limitations under
|
# License for the specific language governing permissions and limitations under
|
||||||
# the License.
|
# the License.
|
||||||
|
|
||||||
|
from tempest.lib.services.object_storage.account_client import AccountClient
|
||||||
from tempest.lib.services.object_storage.bulk_middleware_client import \
|
from tempest.lib.services.object_storage.bulk_middleware_client import \
|
||||||
BulkMiddlewareClient
|
BulkMiddlewareClient
|
||||||
from tempest.lib.services.object_storage.capabilities_client import \
|
from tempest.lib.services.object_storage.capabilities_client import \
|
||||||
CapabilitiesClient
|
CapabilitiesClient
|
||||||
from tempest.services.object_storage.account_client import AccountClient
|
|
||||||
from tempest.services.object_storage.container_client import ContainerClient
|
from tempest.services.object_storage.container_client import ContainerClient
|
||||||
from tempest.services.object_storage.object_client import ObjectClient
|
from tempest.services.object_storage.object_client import ObjectClient
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user