File tree 1 file changed +2
-3
lines changed
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -24,15 +24,13 @@ static S3_RUNTIME: Lazy<Mutex<Runtime>> =
24
24
pub ( crate ) struct S3Backend {
25
25
client : S3Client ,
26
26
bucket : String ,
27
- runtime : & ' static Mutex < Runtime > ,
28
27
}
29
28
30
29
impl S3Backend {
31
30
pub ( crate ) fn new ( client : S3Client , bucket : & str ) -> Self {
32
31
Self {
33
32
client,
34
33
bucket : bucket. into ( ) ,
35
- runtime : & * S3_RUNTIME ,
36
34
}
37
35
}
38
36
@@ -102,7 +100,7 @@ impl<'a> StorageTransaction for S3StorageTransaction<'a> {
102
100
}
103
101
attempts += 1 ;
104
102
105
- match self . s3 . runtime . lock ( ) . block_on ( futures. map ( drop) . collect ( ) ) {
103
+ match S3_RUNTIME . lock ( ) . block_on ( futures. map ( drop) . collect ( ) ) {
106
104
// this batch was successful, start another batch if there are still more files
107
105
Ok ( _) => break ,
108
106
Err ( err) => {
@@ -114,6 +112,7 @@ impl<'a> StorageTransaction for S3StorageTransaction<'a> {
114
112
}
115
113
}
116
114
}
115
+
117
116
Ok ( ( ) )
118
117
}
119
118
You can’t perform that action at this time.
0 commit comments