pub trait ObjectsProvider: Send + Sync {
Show 15 methods
// Required methods
fn create_bucket<'life0, 'async_trait>(
&'life0 self,
name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn head_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn delete_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn put<'life0, 'async_trait>(
&'life0 self,
request: PutRequest,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get<'life0, 'async_trait>(
&'life0 self,
request: GetRequest,
) -> Pin<Box<dyn Future<Output = Result<BufferedObject, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn delete<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
version_id: Option<String>,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<DeleteResult, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn list<'life0, 'async_trait>(
&'life0 self,
target: ReadTarget,
prefix: String,
delimiter: Option<String>,
versions: bool,
page_size: u32,
continuation: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ProviderListPage, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn snapshot<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Snapshot, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn destroy_snapshot<'life0, 'async_trait>(
&'life0 self,
snapshot: SnapshotRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn fork<'life0, 'async_trait>(
&'life0 self,
source: ReadTarget,
destination_name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn create_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
metadata: ObjectMetadata,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<MultipartUpload, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn upload_part<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
part_number: u32,
body: Bytes,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<UploadedPart, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn list_parts<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
) -> Pin<Box<dyn Future<Output = Result<Vec<UploadedPart>, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn complete_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
parts: Vec<UploadedPart>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn abort_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Public semantic provider implemented by memory, customer-hosted, and Acyclic adapters.
Required Methods§
Sourcefn create_bucket<'life0, 'async_trait>(
&'life0 self,
name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_bucket<'life0, 'async_trait>(
&'life0 self,
name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create one permanently versioned bucket.
Sourcefn head_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn head_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Resolve one exact bucket identity.
Sourcefn delete_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_bucket<'life0, 'life1, 'async_trait>(
&'life0 self,
bucket: &'life1 BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete one empty exact bucket identity.
Sourcefn put<'life0, 'async_trait>(
&'life0 self,
request: PutRequest,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn put<'life0, 'async_trait>(
&'life0 self,
request: PutRequest,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create one immutable version.
Sourcefn get<'life0, 'async_trait>(
&'life0 self,
request: GetRequest,
) -> Pin<Box<dyn Future<Output = Result<BufferedObject, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get<'life0, 'async_trait>(
&'life0 self,
request: GetRequest,
) -> Pin<Box<dyn Future<Output = Result<BufferedObject, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Read one immutable version or its visible current selection.
Sourcefn delete<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
version_id: Option<String>,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<DeleteResult, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
version_id: Option<String>,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<DeleteResult, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create a delete marker or delete one exact version.
Sourcefn list<'life0, 'async_trait>(
&'life0 self,
target: ReadTarget,
prefix: String,
delimiter: Option<String>,
versions: bool,
page_size: u32,
continuation: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ProviderListPage, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
target: ReadTarget,
prefix: String,
delimiter: Option<String>,
versions: bool,
page_size: u32,
continuation: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ProviderListPage, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Capture or continue one stable listing.
Sourcefn snapshot<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Snapshot, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn snapshot<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Snapshot, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Atomically capture an immutable whole-bucket snapshot.
Sourcefn destroy_snapshot<'life0, 'async_trait>(
&'life0 self,
snapshot: SnapshotRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn destroy_snapshot<'life0, 'async_trait>(
&'life0 self,
snapshot: SnapshotRef,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Destroy one exact snapshot identity.
Sourcefn fork<'life0, 'async_trait>(
&'life0 self,
source: ReadTarget,
destination_name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn fork<'life0, 'async_trait>(
&'life0 self,
source: ReadTarget,
destination_name: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<Bucket, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Atomically fork a whole bucket or snapshot into an independent bucket.
Sourcefn create_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
metadata: ObjectMetadata,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<MultipartUpload, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
metadata: ObjectMetadata,
condition: Option<Condition>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<MultipartUpload, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create one multipart upload without publishing a version.
Sourcefn upload_part<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
part_number: u32,
body: Bytes,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<UploadedPart, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn upload_part<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
part_number: u32,
body: Bytes,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<UploadedPart, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Upload or replace one exact staged part.
Sourcefn list_parts<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
) -> Pin<Box<dyn Future<Output = Result<Vec<UploadedPart>, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_parts<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
) -> Pin<Box<dyn Future<Output = Result<Vec<UploadedPart>, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List staged parts in ascending part-number order.
Sourcefn complete_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
parts: Vec<UploadedPart>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn complete_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
parts: Vec<UploadedPart>,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<ObjectVersion, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Atomically publish a version from exact staged part receipts.
Sourcefn abort_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn abort_multipart<'life0, 'async_trait>(
&'life0 self,
bucket: BucketRef,
object_key: String,
upload_id: String,
idempotency_key: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<bool, ObjectsError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Abort one exact staged upload.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".