pub struct RustackS3 { /* private fields */ }Expand description
The main S3 provider.
All fields are Arc-wrapped for cheap cloning and shared ownership
across handler tasks.
§Examples
use rustack_s3_core::RustackS3;
use rustack_s3_core::config::S3Config;
let provider = RustackS3::new(S3Config::default());
assert!(!provider.config().gateway_listen.is_empty());Implementations§
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_create_bucket(
&self,
input: CreateBucketInput,
) -> Result<CreateBucketOutput, S3Error>
pub async fn handle_create_bucket( &self, input: CreateBucketInput, ) -> Result<CreateBucketOutput, S3Error>
Create a new S3 bucket.
Sourcepub async fn handle_delete_bucket(
&self,
input: DeleteBucketInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket( &self, input: DeleteBucketInput, ) -> Result<(), S3Error>
Delete an S3 bucket.
Sourcepub async fn handle_head_bucket(
&self,
input: HeadBucketInput,
) -> Result<HeadBucketOutput, S3Error>
pub async fn handle_head_bucket( &self, input: HeadBucketInput, ) -> Result<HeadBucketOutput, S3Error>
Check if a bucket exists and is accessible (HEAD Bucket).
Sourcepub async fn handle_list_buckets(
&self,
_input: ListBucketsInput,
) -> Result<ListBucketsOutput, S3Error>
pub async fn handle_list_buckets( &self, _input: ListBucketsInput, ) -> Result<ListBucketsOutput, S3Error>
List all buckets.
Sourcepub async fn handle_get_bucket_location(
&self,
input: GetBucketLocationInput,
) -> Result<GetBucketLocationOutput, S3Error>
pub async fn handle_get_bucket_location( &self, input: GetBucketLocationInput, ) -> Result<GetBucketLocationOutput, S3Error>
Get the location (region) of a bucket.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_get_bucket_versioning(
&self,
input: GetBucketVersioningInput,
) -> Result<GetBucketVersioningOutput, S3Error>
pub async fn handle_get_bucket_versioning( &self, input: GetBucketVersioningInput, ) -> Result<GetBucketVersioningOutput, S3Error>
Get the versioning configuration for a bucket.
Sourcepub async fn handle_put_bucket_versioning(
&self,
input: PutBucketVersioningInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_versioning( &self, input: PutBucketVersioningInput, ) -> Result<(), S3Error>
Set the versioning configuration for a bucket.
Sourcepub async fn handle_get_bucket_encryption(
&self,
input: GetBucketEncryptionInput,
) -> Result<GetBucketEncryptionOutput, S3Error>
pub async fn handle_get_bucket_encryption( &self, input: GetBucketEncryptionInput, ) -> Result<GetBucketEncryptionOutput, S3Error>
Get the server-side encryption configuration for a bucket.
Sourcepub async fn handle_put_bucket_encryption(
&self,
input: PutBucketEncryptionInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_encryption( &self, input: PutBucketEncryptionInput, ) -> Result<(), S3Error>
Set the server-side encryption configuration for a bucket.
Sourcepub async fn handle_delete_bucket_encryption(
&self,
input: DeleteBucketEncryptionInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_encryption( &self, input: DeleteBucketEncryptionInput, ) -> Result<(), S3Error>
Delete the server-side encryption configuration for a bucket.
Sourcepub async fn handle_get_bucket_cors(
&self,
input: GetBucketCorsInput,
) -> Result<GetBucketCorsOutput, S3Error>
pub async fn handle_get_bucket_cors( &self, input: GetBucketCorsInput, ) -> Result<GetBucketCorsOutput, S3Error>
Get CORS configuration for a bucket.
Sourcepub async fn handle_put_bucket_cors(
&self,
input: PutBucketCorsInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_cors( &self, input: PutBucketCorsInput, ) -> Result<(), S3Error>
Set CORS configuration for a bucket.
Sourcepub async fn handle_delete_bucket_cors(
&self,
input: DeleteBucketCorsInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_cors( &self, input: DeleteBucketCorsInput, ) -> Result<(), S3Error>
Delete CORS configuration for a bucket.
Sourcepub async fn handle_get_bucket_lifecycle_configuration(
&self,
input: GetBucketLifecycleConfigurationInput,
) -> Result<GetBucketLifecycleConfigurationOutput, S3Error>
pub async fn handle_get_bucket_lifecycle_configuration( &self, input: GetBucketLifecycleConfigurationInput, ) -> Result<GetBucketLifecycleConfigurationOutput, S3Error>
Get lifecycle configuration for a bucket.
Sourcepub async fn handle_put_bucket_lifecycle_configuration(
&self,
input: PutBucketLifecycleConfigurationInput,
) -> Result<PutBucketLifecycleConfigurationOutput, S3Error>
pub async fn handle_put_bucket_lifecycle_configuration( &self, input: PutBucketLifecycleConfigurationInput, ) -> Result<PutBucketLifecycleConfigurationOutput, S3Error>
Set lifecycle configuration for a bucket.
Sourcepub async fn handle_delete_bucket_lifecycle(
&self,
input: DeleteBucketLifecycleInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_lifecycle( &self, input: DeleteBucketLifecycleInput, ) -> Result<(), S3Error>
Delete lifecycle configuration for a bucket.
Sourcepub async fn handle_get_bucket_policy(
&self,
input: GetBucketPolicyInput,
) -> Result<GetBucketPolicyOutput, S3Error>
pub async fn handle_get_bucket_policy( &self, input: GetBucketPolicyInput, ) -> Result<GetBucketPolicyOutput, S3Error>
Get the bucket policy.
Sourcepub async fn handle_put_bucket_policy(
&self,
input: PutBucketPolicyInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_policy( &self, input: PutBucketPolicyInput, ) -> Result<(), S3Error>
Set the bucket policy.
Sourcepub async fn handle_delete_bucket_policy(
&self,
input: DeleteBucketPolicyInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_policy( &self, input: DeleteBucketPolicyInput, ) -> Result<(), S3Error>
Delete the bucket policy.
Sourcepub async fn handle_get_bucket_tagging(
&self,
input: GetBucketTaggingInput,
) -> Result<GetBucketTaggingOutput, S3Error>
pub async fn handle_get_bucket_tagging( &self, input: GetBucketTaggingInput, ) -> Result<GetBucketTaggingOutput, S3Error>
Get the tag set for a bucket.
Sourcepub async fn handle_put_bucket_tagging(
&self,
input: PutBucketTaggingInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_tagging( &self, input: PutBucketTaggingInput, ) -> Result<(), S3Error>
Set the tag set for a bucket.
Sourcepub async fn handle_delete_bucket_tagging(
&self,
input: DeleteBucketTaggingInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_tagging( &self, input: DeleteBucketTaggingInput, ) -> Result<(), S3Error>
Delete the tag set for a bucket.
Sourcepub async fn handle_get_bucket_notification_configuration(
&self,
input: GetBucketNotificationConfigurationInput,
) -> Result<GetBucketNotificationConfigurationOutput, S3Error>
pub async fn handle_get_bucket_notification_configuration( &self, input: GetBucketNotificationConfigurationInput, ) -> Result<GetBucketNotificationConfigurationOutput, S3Error>
Get notification configuration for a bucket.
Sourcepub async fn handle_put_bucket_notification_configuration(
&self,
input: PutBucketNotificationConfigurationInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_notification_configuration( &self, input: PutBucketNotificationConfigurationInput, ) -> Result<(), S3Error>
Set notification configuration for a bucket.
Sourcepub async fn handle_get_bucket_logging(
&self,
input: GetBucketLoggingInput,
) -> Result<GetBucketLoggingOutput, S3Error>
pub async fn handle_get_bucket_logging( &self, input: GetBucketLoggingInput, ) -> Result<GetBucketLoggingOutput, S3Error>
Get logging configuration for a bucket.
Sourcepub async fn handle_put_bucket_logging(
&self,
input: PutBucketLoggingInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_logging( &self, input: PutBucketLoggingInput, ) -> Result<(), S3Error>
Set logging configuration for a bucket.
Sourcepub async fn handle_get_public_access_block(
&self,
input: GetPublicAccessBlockInput,
) -> Result<GetPublicAccessBlockOutput, S3Error>
pub async fn handle_get_public_access_block( &self, input: GetPublicAccessBlockInput, ) -> Result<GetPublicAccessBlockOutput, S3Error>
Get public access block configuration for a bucket.
Sourcepub async fn handle_put_public_access_block(
&self,
input: PutPublicAccessBlockInput,
) -> Result<(), S3Error>
pub async fn handle_put_public_access_block( &self, input: PutPublicAccessBlockInput, ) -> Result<(), S3Error>
Set public access block configuration for a bucket.
Sourcepub async fn handle_delete_public_access_block(
&self,
input: DeletePublicAccessBlockInput,
) -> Result<(), S3Error>
pub async fn handle_delete_public_access_block( &self, input: DeletePublicAccessBlockInput, ) -> Result<(), S3Error>
Delete public access block configuration for a bucket.
Sourcepub async fn handle_get_bucket_ownership_controls(
&self,
input: GetBucketOwnershipControlsInput,
) -> Result<GetBucketOwnershipControlsOutput, S3Error>
pub async fn handle_get_bucket_ownership_controls( &self, input: GetBucketOwnershipControlsInput, ) -> Result<GetBucketOwnershipControlsOutput, S3Error>
Get ownership controls configuration for a bucket.
Sourcepub async fn handle_put_bucket_ownership_controls(
&self,
input: PutBucketOwnershipControlsInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_ownership_controls( &self, input: PutBucketOwnershipControlsInput, ) -> Result<(), S3Error>
Set ownership controls configuration for a bucket.
Sourcepub async fn handle_delete_bucket_ownership_controls(
&self,
input: DeleteBucketOwnershipControlsInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_ownership_controls( &self, input: DeleteBucketOwnershipControlsInput, ) -> Result<(), S3Error>
Delete ownership controls configuration for a bucket.
Sourcepub async fn handle_get_object_lock_configuration(
&self,
input: GetObjectLockConfigurationInput,
) -> Result<GetObjectLockConfigurationOutput, S3Error>
pub async fn handle_get_object_lock_configuration( &self, input: GetObjectLockConfigurationInput, ) -> Result<GetObjectLockConfigurationOutput, S3Error>
Get object lock configuration for a bucket.
Sourcepub async fn handle_put_object_lock_configuration(
&self,
input: PutObjectLockConfigurationInput,
) -> Result<PutObjectLockConfigurationOutput, S3Error>
pub async fn handle_put_object_lock_configuration( &self, input: PutObjectLockConfigurationInput, ) -> Result<PutObjectLockConfigurationOutput, S3Error>
Set object lock configuration for a bucket.
Sourcepub async fn handle_get_bucket_accelerate_configuration(
&self,
input: GetBucketAccelerateConfigurationInput,
) -> Result<GetBucketAccelerateConfigurationOutput, S3Error>
pub async fn handle_get_bucket_accelerate_configuration( &self, input: GetBucketAccelerateConfigurationInput, ) -> Result<GetBucketAccelerateConfigurationOutput, S3Error>
Get the transfer acceleration configuration for a bucket.
Sourcepub async fn handle_put_bucket_accelerate_configuration(
&self,
input: PutBucketAccelerateConfigurationInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_accelerate_configuration( &self, input: PutBucketAccelerateConfigurationInput, ) -> Result<(), S3Error>
Set the transfer acceleration configuration for a bucket.
Sourcepub async fn handle_get_bucket_request_payment(
&self,
input: GetBucketRequestPaymentInput,
) -> Result<GetBucketRequestPaymentOutput, S3Error>
pub async fn handle_get_bucket_request_payment( &self, input: GetBucketRequestPaymentInput, ) -> Result<GetBucketRequestPaymentOutput, S3Error>
Get the request payment configuration for a bucket.
Sourcepub async fn handle_put_bucket_request_payment(
&self,
input: PutBucketRequestPaymentInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_request_payment( &self, input: PutBucketRequestPaymentInput, ) -> Result<(), S3Error>
Set the request payment configuration for a bucket.
Sourcepub async fn handle_get_bucket_website(
&self,
input: GetBucketWebsiteInput,
) -> Result<GetBucketWebsiteOutput, S3Error>
pub async fn handle_get_bucket_website( &self, input: GetBucketWebsiteInput, ) -> Result<GetBucketWebsiteOutput, S3Error>
Get the website configuration for a bucket.
Sourcepub async fn handle_put_bucket_website(
&self,
input: PutBucketWebsiteInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_website( &self, input: PutBucketWebsiteInput, ) -> Result<(), S3Error>
Set the website configuration for a bucket.
Sourcepub async fn handle_delete_bucket_website(
&self,
input: DeleteBucketWebsiteInput,
) -> Result<(), S3Error>
pub async fn handle_delete_bucket_website( &self, input: DeleteBucketWebsiteInput, ) -> Result<(), S3Error>
Delete the website configuration for a bucket.
Sourcepub async fn handle_get_bucket_acl(
&self,
input: GetBucketAclInput,
) -> Result<GetBucketAclOutput, S3Error>
pub async fn handle_get_bucket_acl( &self, input: GetBucketAclInput, ) -> Result<GetBucketAclOutput, S3Error>
Get the ACL for a bucket.
Sourcepub async fn handle_put_bucket_acl(
&self,
input: PutBucketAclInput,
) -> Result<(), S3Error>
pub async fn handle_put_bucket_acl( &self, input: PutBucketAclInput, ) -> Result<(), S3Error>
Set the ACL for a bucket.
Sourcepub async fn handle_get_bucket_policy_status(
&self,
input: GetBucketPolicyStatusInput,
) -> Result<GetBucketPolicyStatusOutput, S3Error>
pub async fn handle_get_bucket_policy_status( &self, input: GetBucketPolicyStatusInput, ) -> Result<GetBucketPolicyStatusOutput, S3Error>
Get the policy status for a bucket.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_list_objects(
&self,
input: ListObjectsInput,
) -> Result<ListObjectsOutput, S3Error>
pub async fn handle_list_objects( &self, input: ListObjectsInput, ) -> Result<ListObjectsOutput, S3Error>
List objects (v1 API).
Sourcepub async fn handle_list_objects_v2(
&self,
input: ListObjectsV2Input,
) -> Result<ListObjectsV2Output, S3Error>
pub async fn handle_list_objects_v2( &self, input: ListObjectsV2Input, ) -> Result<ListObjectsV2Output, S3Error>
List objects (v2 API with continuation tokens).
Sourcepub async fn handle_list_object_versions(
&self,
input: ListObjectVersionsInput,
) -> Result<ListObjectVersionsOutput, S3Error>
pub async fn handle_list_object_versions( &self, input: ListObjectVersionsInput, ) -> Result<ListObjectVersionsOutput, S3Error>
List object versions.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_create_multipart_upload(
&self,
input: CreateMultipartUploadInput,
) -> Result<CreateMultipartUploadOutput, S3Error>
pub async fn handle_create_multipart_upload( &self, input: CreateMultipartUploadInput, ) -> Result<CreateMultipartUploadOutput, S3Error>
Create a new multipart upload.
Sourcepub async fn handle_upload_part(
&self,
input: UploadPartInput,
) -> Result<UploadPartOutput, S3Error>
pub async fn handle_upload_part( &self, input: UploadPartInput, ) -> Result<UploadPartOutput, S3Error>
Upload a single part of a multipart upload.
Sourcepub async fn handle_upload_part_copy(
&self,
input: UploadPartCopyInput,
) -> Result<UploadPartCopyOutput, S3Error>
pub async fn handle_upload_part_copy( &self, input: UploadPartCopyInput, ) -> Result<UploadPartCopyOutput, S3Error>
Upload a part by copying from an existing object.
Sourcepub async fn handle_complete_multipart_upload(
&self,
input: CompleteMultipartUploadInput,
) -> Result<CompleteMultipartUploadOutput, S3Error>
pub async fn handle_complete_multipart_upload( &self, input: CompleteMultipartUploadInput, ) -> Result<CompleteMultipartUploadOutput, S3Error>
Complete a multipart upload by assembling parts into the final object.
Sourcepub async fn handle_abort_multipart_upload(
&self,
input: AbortMultipartUploadInput,
) -> Result<AbortMultipartUploadOutput, S3Error>
pub async fn handle_abort_multipart_upload( &self, input: AbortMultipartUploadInput, ) -> Result<AbortMultipartUploadOutput, S3Error>
Abort a multipart upload.
Sourcepub async fn handle_list_parts(
&self,
input: ListPartsInput,
) -> Result<ListPartsOutput, S3Error>
pub async fn handle_list_parts( &self, input: ListPartsInput, ) -> Result<ListPartsOutput, S3Error>
List parts that have been uploaded for a multipart upload.
Sourcepub async fn handle_list_multipart_uploads(
&self,
input: ListMultipartUploadsInput,
) -> Result<ListMultipartUploadsOutput, S3Error>
pub async fn handle_list_multipart_uploads( &self, input: ListMultipartUploadsInput, ) -> Result<ListMultipartUploadsOutput, S3Error>
List in-progress multipart uploads for a bucket.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_put_object(
&self,
input: PutObjectInput,
) -> Result<PutObjectOutput, S3Error>
pub async fn handle_put_object( &self, input: PutObjectInput, ) -> Result<PutObjectOutput, S3Error>
Put (upload) a new object.
Sourcepub async fn handle_get_object(
&self,
input: GetObjectInput,
) -> Result<GetObjectOutput, S3Error>
pub async fn handle_get_object( &self, input: GetObjectInput, ) -> Result<GetObjectOutput, S3Error>
Get (download) an object.
Sourcepub async fn handle_head_object(
&self,
input: HeadObjectInput,
) -> Result<HeadObjectOutput, S3Error>
pub async fn handle_head_object( &self, input: HeadObjectInput, ) -> Result<HeadObjectOutput, S3Error>
Head object (get metadata without body).
Sourcepub async fn handle_delete_object(
&self,
input: DeleteObjectInput,
) -> Result<DeleteObjectOutput, S3Error>
pub async fn handle_delete_object( &self, input: DeleteObjectInput, ) -> Result<DeleteObjectOutput, S3Error>
Delete a single object.
Sourcepub async fn handle_delete_objects(
&self,
input: DeleteObjectsInput,
) -> Result<DeleteObjectsOutput, S3Error>
pub async fn handle_delete_objects( &self, input: DeleteObjectsInput, ) -> Result<DeleteObjectsOutput, S3Error>
Delete multiple objects (bulk delete).
Sourcepub async fn handle_copy_object(
&self,
input: CopyObjectInput,
) -> Result<CopyObjectOutput, S3Error>
pub async fn handle_copy_object( &self, input: CopyObjectInput, ) -> Result<CopyObjectOutput, S3Error>
Copy an object from a source to a destination.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn handle_get_object_tagging(
&self,
input: GetObjectTaggingInput,
) -> Result<GetObjectTaggingOutput, S3Error>
pub async fn handle_get_object_tagging( &self, input: GetObjectTaggingInput, ) -> Result<GetObjectTaggingOutput, S3Error>
Get tags for an object.
Sourcepub async fn handle_put_object_tagging(
&self,
input: PutObjectTaggingInput,
) -> Result<PutObjectTaggingOutput, S3Error>
pub async fn handle_put_object_tagging( &self, input: PutObjectTaggingInput, ) -> Result<PutObjectTaggingOutput, S3Error>
Set tags for an object.
Sourcepub async fn handle_delete_object_tagging(
&self,
input: DeleteObjectTaggingInput,
) -> Result<DeleteObjectTaggingOutput, S3Error>
pub async fn handle_delete_object_tagging( &self, input: DeleteObjectTaggingInput, ) -> Result<DeleteObjectTaggingOutput, S3Error>
Delete tags for an object.
Sourcepub async fn handle_get_object_acl(
&self,
input: GetObjectAclInput,
) -> Result<GetObjectAclOutput, S3Error>
pub async fn handle_get_object_acl( &self, input: GetObjectAclInput, ) -> Result<GetObjectAclOutput, S3Error>
Get the ACL for an object.
Sourcepub async fn handle_put_object_acl(
&self,
input: PutObjectAclInput,
) -> Result<PutObjectAclOutput, S3Error>
pub async fn handle_put_object_acl( &self, input: PutObjectAclInput, ) -> Result<PutObjectAclOutput, S3Error>
Set the ACL for an object.
Sourcepub async fn handle_get_object_retention(
&self,
input: GetObjectRetentionInput,
) -> Result<GetObjectRetentionOutput, S3Error>
pub async fn handle_get_object_retention( &self, input: GetObjectRetentionInput, ) -> Result<GetObjectRetentionOutput, S3Error>
Get the retention configuration for an object.
Sourcepub async fn handle_put_object_retention(
&self,
input: PutObjectRetentionInput,
) -> Result<PutObjectRetentionOutput, S3Error>
pub async fn handle_put_object_retention( &self, input: PutObjectRetentionInput, ) -> Result<PutObjectRetentionOutput, S3Error>
Set the retention configuration for an object.
Sourcepub async fn handle_get_object_legal_hold(
&self,
input: GetObjectLegalHoldInput,
) -> Result<GetObjectLegalHoldOutput, S3Error>
pub async fn handle_get_object_legal_hold( &self, input: GetObjectLegalHoldInput, ) -> Result<GetObjectLegalHoldOutput, S3Error>
Get the legal hold status for an object.
Sourcepub async fn handle_put_object_legal_hold(
&self,
input: PutObjectLegalHoldInput,
) -> Result<PutObjectLegalHoldOutput, S3Error>
pub async fn handle_put_object_legal_hold( &self, input: PutObjectLegalHoldInput, ) -> Result<PutObjectLegalHoldOutput, S3Error>
Set the legal hold status for an object.
Sourcepub async fn handle_get_object_attributes(
&self,
input: GetObjectAttributesInput,
) -> Result<GetObjectAttributesOutput, S3Error>
pub async fn handle_get_object_attributes( &self, input: GetObjectAttributesInput, ) -> Result<GetObjectAttributesOutput, S3Error>
Get attributes for an object.
Source§impl RustackS3
impl RustackS3
Sourcepub fn new(config: S3Config) -> Self
pub fn new(config: S3Config) -> Self
Create a new S3 provider with the given configuration.
Initializes an empty service state, a storage backend configured with
the memory threshold from config, and an empty CORS index.
Sourcepub fn state(&self) -> &S3ServiceState
pub fn state(&self) -> &S3ServiceState
Returns a reference to the service state.
Sourcepub fn storage(&self) -> &InMemoryStorage
pub fn storage(&self) -> &InMemoryStorage
Returns a reference to the storage backend.
Sourcepub fn cors_index(&self) -> &CorsIndex
pub fn cors_index(&self) -> &CorsIndex
Returns a reference to the CORS index.
Source§impl RustackS3
impl RustackS3
Sourcepub async fn export_snapshot(
&self,
data_dir: &Path,
) -> Result<S3Snapshot, S3SnapshotError>
pub async fn export_snapshot( &self, data_dir: &Path, ) -> Result<S3Snapshot, S3SnapshotError>
Export S3 state and object bodies into a snapshot.
§Errors
Returns an error if object bodies cannot be read or written.
Sourcepub async fn import_snapshot(
&self,
snapshot: S3Snapshot,
data_dir: &Path,
) -> Result<(), S3SnapshotError>
pub async fn import_snapshot( &self, snapshot: S3Snapshot, data_dir: &Path, ) -> Result<(), S3SnapshotError>
Import S3 state and object bodies from a snapshot.
§Errors
Returns an error if object body files cannot be read or restored.