File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,14 @@ class Storage < Fog::Service
14
14
'https' => 443
15
15
}
16
16
17
+ DEFAULT_CONNECTION_OPTIONS = {
18
+ retry_limit : 5 ,
19
+ retry_interval : 1 ,
20
+ retry_errors : [
21
+ Excon ::Error ::Timeout , Excon ::Error ::Socket , Excon ::Error ::Server
22
+ ]
23
+ }
24
+
17
25
MIN_MULTIPART_CHUNK_SIZE = 5242880
18
26
MAX_SINGLE_PUT_SIZE = 5368709120
19
27
@@ -546,7 +554,8 @@ def initialize(options={})
546
554
@use_iam_profile = options [ :use_iam_profile ]
547
555
@instrumentor = options [ :instrumentor ]
548
556
@instrumentor_name = options [ :instrumentor_name ] || 'fog.aws.storage'
549
- @connection_options = options [ :connection_options ] || { retry_limit : 5 , retry_interval : 1 }
557
+ @connection_options =
558
+ DEFAULT_CONNECTION_OPTIONS . merge ( options [ :connection_options ] || { } )
550
559
@persistent = options . fetch ( :persistent , false )
551
560
@acceleration = options . fetch ( :acceleration , false )
552
561
@signature_version = options . fetch ( :aws_signature_version , 4 )
You can’t perform that action at this time.
0 commit comments