@@ -99,10 +99,9 @@ public void testOneChunkUpload() {
99
99
CompletableFuture <Void > resultFuture = asyncTransferManager .uploadObject (
100
100
s3AsyncClient ,
101
101
new UploadRequest ("bucket" , "key" , ByteSizeUnit .MB .toBytes (1 ), WritePriority .HIGH , uploadSuccess -> {
102
-
103
- }, false , null , true , metadata , null , ServerSideEncryption .AWS_KMS .toString (), randomAlphaOfLength (10 ), true , null , null ),
104
102
105
-
103
+ }, false , null , true , metadata , null , ServerSideEncryption .AWS_KMS .toString (), randomAlphaOfLength (10 ), true , null , null ),
104
+
106
105
new StreamContext ((partIdx , partSize , position ) -> {
107
106
streamRef .set (new ZeroInputStream (partSize ));
108
107
return new InputStreamContainer (streamRef .get (), partSize , position );
@@ -146,11 +145,26 @@ public void testOneChunkUploadCorruption() {
146
145
Map <String , String > metadata = new HashMap <>();
147
146
metadata .put ("key1" , "value1" );
148
147
metadata .put ("key2" , "value2" );
149
-
148
+
150
149
CompletableFuture <Void > resultFuture = asyncTransferManager .uploadObject (
151
150
s3AsyncClient ,
152
- new UploadRequest ("bucket" , "key" , ByteSizeUnit .MB .toBytes (1 ), WritePriority .HIGH , uploadSuccess -> {
153
- }, false , null , true , metadata , null , ServerSideEncryption .AWS_KMS .toString (), randomAlphaOfLength (10 ), true , null , null ),
151
+ new UploadRequest (
152
+ "bucket" ,
153
+ "key" ,
154
+ ByteSizeUnit .MB .toBytes (1 ),
155
+ WritePriority .HIGH ,
156
+ uploadSuccess -> {},
157
+ false ,
158
+ null ,
159
+ true ,
160
+ metadata ,
161
+ null ,
162
+ ServerSideEncryption .AWS_KMS .toString (),
163
+ randomAlphaOfLength (10 ),
164
+ true ,
165
+ null ,
166
+ null
167
+ ),
154
168
new StreamContext (
155
169
(partIdx , partSize , position ) -> new InputStreamContainer (new ZeroInputStream (partSize ), partSize , position ),
156
170
ByteSizeUnit .MB .toBytes (1 ),
@@ -206,7 +220,7 @@ public void testMultipartUpload() {
206
220
CompletableFuture <Void > resultFuture = asyncTransferManager .uploadObject (
207
221
s3AsyncClient ,
208
222
new UploadRequest ("bucket" , "key" , ByteSizeUnit .MB .toBytes (5 ), WritePriority .HIGH , uploadSuccess -> {
209
-
223
+
210
224
}, true , 3376132981L , true , metadata , null , ServerSideEncryption .AWS_KMS .toString (), randomAlphaOfLength (10 ), true , null , null ),
211
225
212
226
new StreamContext ((partIdx , partSize , position ) -> {
@@ -323,12 +337,12 @@ public void testConditionalOneChunkUpload() {
323
337
null ,
324
338
true ,
325
339
metadata ,
326
- options ,
327
- null ,
328
- null ,
329
- false ,
330
- null ,
331
- null
340
+ options ,
341
+ null ,
342
+ null ,
343
+ false ,
344
+ null ,
345
+ null
332
346
),
333
347
new StreamContext ((partIdx , partSize , position ) -> {
334
348
streamRef .set (new ZeroInputStream (partSize ));
@@ -381,12 +395,12 @@ public void testConditionalOneChunkUploadPreconditionFailed() {
381
395
null ,
382
396
true ,
383
397
null ,
384
- options ,
385
- null ,
386
- null ,
387
- false ,
388
- null ,
389
- null
398
+ options ,
399
+ null ,
400
+ null ,
401
+ false ,
402
+ null ,
403
+ null
390
404
),
391
405
new StreamContext ((partIdx , partSize , position ) -> {
392
406
streamRef .set (new ZeroInputStream (partSize ));
@@ -451,12 +465,12 @@ public void testConditionalOneChunkUploadCorruption() {
451
465
null ,
452
466
true ,
453
467
null ,
454
- options ,
455
- null ,
456
- null ,
457
- false ,
458
- null ,
459
- null
468
+ options ,
469
+ null ,
470
+ null ,
471
+ false ,
472
+ null ,
473
+ null
460
474
),
461
475
new StreamContext ((partIdx , partSize , position ) -> {
462
476
streamRef .set (new ZeroInputStream (partSize ));
@@ -528,12 +542,12 @@ public void testConditionalMultipartUploadPreconditionFailed() {
528
542
3376132981L ,
529
543
true ,
530
544
null ,
531
- options ,
532
- null ,
533
- null ,
534
- false ,
535
- null ,
536
- null
545
+ options ,
546
+ null ,
547
+ null ,
548
+ false ,
549
+ null ,
550
+ null
537
551
),
538
552
new StreamContext ((partIdx , partSize , position ) -> {
539
553
InputStream stream = new ZeroInputStream (partSize );
@@ -604,13 +618,13 @@ public void testConditionalMultipartUploadCorruption() {
604
618
0L ,
605
619
true ,
606
620
null ,
607
- options ,
608
- null ,
609
- null ,
610
- false ,
611
- null ,
612
- null
613
- ),
621
+ options ,
622
+ null ,
623
+ null ,
624
+ false ,
625
+ null ,
626
+ null
627
+ ),
614
628
new StreamContext ((partIdx , partSize , position ) -> {
615
629
InputStream stream = new ZeroInputStream (partSize );
616
630
streams .add (stream );
0 commit comments