@@ -16,7 +16,7 @@ pub struct BlobStoreS3 {
16
16
aws_sdk_s3:: Client ,
17
17
std:: pin:: Pin < Box < dyn std:: future:: Future < Output = aws_sdk_s3:: Client > + Send > > ,
18
18
> ,
19
- container_name : Option < String > ,
19
+ bucket : Option < String > ,
20
20
}
21
21
22
22
/// AWS S3 runtime config literal options for authentication
@@ -70,7 +70,7 @@ impl BlobStoreS3 {
70
70
pub fn new (
71
71
region : String ,
72
72
auth_options : BlobStoreS3AuthOptions ,
73
- container_name : Option < String > ,
73
+ bucket : Option < String > ,
74
74
) -> Result < Self > {
75
75
let builder = match & auth_options {
76
76
BlobStoreS3AuthOptions :: RuntimeConfigValues ( config) =>
@@ -97,14 +97,14 @@ impl BlobStoreS3 {
97
97
aws_sdk_s3:: Client :: new ( & sdk_config)
98
98
} ) ;
99
99
100
- Ok ( Self { builder, client : async_once_cell:: Lazy :: from_future ( client_fut) , container_name } )
100
+ Ok ( Self { builder, client : async_once_cell:: Lazy :: from_future ( client_fut) , bucket } )
101
101
}
102
102
}
103
103
104
104
#[ async_trait]
105
105
impl ContainerManager for BlobStoreS3 {
106
106
async fn get ( & self , name : & str ) -> Result < Arc < dyn Container > , Error > {
107
- let name = self . container_name . clone ( ) . unwrap_or_else ( || name. to_owned ( ) ) ;
107
+ let name = self . bucket . clone ( ) . unwrap_or_else ( || name. to_owned ( ) ) ;
108
108
109
109
let store = self . builder . clone ( ) . with_bucket_name ( & name) . build ( ) . map_err ( |e| e. to_string ( ) ) ?;
110
110
0 commit comments