File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ actix-cors = "0.6"
1515actix-files = " 0.6.1"
1616anyhow = { version = " 1.0.43" , features = [" backtrace" ] }
1717async-trait = " 0.1"
18- aws-sdk-s3 = " 0.17"
18+ aws-sdk-s3 = " 0.19"
19+ aws-smithy-async = { version = " 0.49.0" , features = [" rt-tokio" ] }
1920bytes = " 1"
2021chrono = " 0.4.19"
2122chrono-humanize = " 0.2.2"
Original file line number Diff line number Diff line change @@ -3,7 +3,9 @@ use aws_sdk_s3::error::{HeadBucketError, HeadBucketErrorKind};
33use aws_sdk_s3:: model:: { CommonPrefix , Delete , ObjectIdentifier } ;
44use aws_sdk_s3:: types:: { ByteStream , SdkError } ;
55use aws_sdk_s3:: Error as AwsSdkError ;
6+ use aws_sdk_s3:: RetryConfig ;
67use aws_sdk_s3:: { Client , Credentials , Endpoint , Region } ;
8+ use aws_smithy_async:: rt:: sleep:: default_async_sleep;
79use bytes:: Bytes ;
810use crossterm:: style:: Stylize ;
911use datafusion:: arrow:: datatypes:: Schema ;
@@ -171,6 +173,8 @@ impl S3 {
171173 . region ( options. region )
172174 . endpoint_resolver ( options. endpoint )
173175 . credentials_provider ( options. creds )
176+ . retry_config ( RetryConfig :: standard ( ) . with_max_attempts ( 5 ) )
177+ . sleep_impl ( default_async_sleep ( ) . expect ( "sleep impl is provided for tokio rt" ) )
174178 . build ( ) ;
175179
176180 let client = Client :: from_conf ( config) ;
You can’t perform that action at this time.
0 commit comments