Struct objectscale_client::client::ObjectstoreClient
source · pub struct ObjectstoreClient { /* private fields */ }Implementations§
source§impl ObjectstoreClient
impl ObjectstoreClient
sourcepub fn create_bucket(&mut self, bucket: Bucket) -> Result<Bucket>
pub fn create_bucket(&mut self, bucket: Bucket) -> Result<Bucket>
Create an bucket.
bucket: Bucket to create.
sourcepub fn get_bucket(&mut self, name: &str, namespace: &str) -> Result<Bucket>
pub fn get_bucket(&mut self, name: &str, namespace: &str) -> Result<Bucket>
Gets bucket information for the specified bucket.
name: Bucket name for which information will be retrieved. Cannot be empty. namespace: Namespace associated. Cannot be empty.
sourcepub fn delete_bucket(
&mut self,
name: &str,
namespace: &str,
empty_bucket: bool,
) -> Result<()>
pub fn delete_bucket( &mut self, name: &str, namespace: &str, empty_bucket: bool, ) -> Result<()>
Deletes the specified bucket.
name: Bucket name to be deleted. Cannot be empty. namespace: Namespace associated. Cannot be empty. emptyBucket: If true, the contents of the bucket will be emptied as part of the delete, otherwise it will fail if the bucket is not empty..
sourcepub fn list_buckets(
&mut self,
namespace: &str,
name_prefix: &str,
) -> Result<Vec<Bucket>>
pub fn list_buckets( &mut self, namespace: &str, name_prefix: &str, ) -> Result<Vec<Bucket>>
Gets the list of buckets for the specified namespace.
namespace: Namespace for which buckets should be listed. Cannot be empty. name_prefix: Case sensitive prefix of the Bucket name with a wild card(). Can be empty or any_prefix_string.
sourcepub fn create_tenant(&mut self, tenant: Tenant) -> Result<Tenant>
pub fn create_tenant(&mut self, tenant: Tenant) -> Result<Tenant>
Creates the tenant which will associate an IAM Account within an objectstore.
tenant: Tenant to create
sourcepub fn delete_tenant(&mut self, name: &str) -> Result<()>
pub fn delete_tenant(&mut self, name: &str) -> Result<()>
Delete the tenant from an object store. Tenant must not own any buckets.
name: The associated account id. Cannot be empty.
sourcepub fn get_tenant(&mut self, name: &str) -> Result<Tenant>
pub fn get_tenant(&mut self, name: &str) -> Result<Tenant>
Get the tenant.
name: The associated account id. Cannot be empty.