feat(bucket): expose the underlying S3 client through getStorageClient()
This commit is contained in:
@@ -49,6 +49,20 @@ export class Bucket {
|
||||
this.name = bucketName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the underlying AWS SDK v3 S3Client for this bucket.
|
||||
*
|
||||
* Use this when you need to perform operations smartbucket doesn't
|
||||
* wrap directly (e.g. lifecycle policies, bucket tagging, multipart
|
||||
* upload control, object-lock, inventory config, etc.).
|
||||
*
|
||||
* The returned client is shared with the parent SmartBucket — do not
|
||||
* call `.destroy()` on it.
|
||||
*/
|
||||
public getStorageClient(): plugins.s3.S3Client {
|
||||
return this.smartbucketRef.storageClient;
|
||||
}
|
||||
|
||||
/**
|
||||
* gets the base directory of the bucket
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user