aws-sdk-s3 1.73.0 → 1.78.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/aws-sdk-s3.rb +1 -1
- data/lib/aws-sdk-s3/bucket.rb +2 -2
- data/lib/aws-sdk-s3/client.rb +127 -114
- data/lib/aws-sdk-s3/customizations/object.rb +12 -1
- data/lib/aws-sdk-s3/encryption.rb +2 -0
- data/lib/aws-sdk-s3/encryption/client.rb +11 -0
- data/lib/aws-sdk-s3/encryption/decrypt_handler.rb +64 -29
- data/lib/aws-sdk-s3/encryption/default_cipher_provider.rb +41 -5
- data/lib/aws-sdk-s3/encryption/encrypt_handler.rb +5 -5
- data/lib/aws-sdk-s3/encryption/io_decrypter.rb +7 -6
- data/lib/aws-sdk-s3/encryption/kms_cipher_provider.rb +32 -3
- data/lib/aws-sdk-s3/encryption/utils.rb +23 -0
- data/lib/aws-sdk-s3/encryptionV2/client.rb +201 -23
- data/lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb +40 -12
- data/lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb +77 -10
- data/lib/aws-sdk-s3/encryptionV2/default_key_provider.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb +7 -4
- data/lib/aws-sdk-s3/encryptionV2/errors.rb +24 -0
- data/lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/io_decrypter.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/io_encrypter.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/key_provider.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb +90 -20
- data/lib/aws-sdk-s3/encryptionV2/materials.rb +2 -0
- data/lib/aws-sdk-s3/encryptionV2/utils.rb +2 -15
- data/lib/aws-sdk-s3/encryption_v2.rb +4 -1
- data/lib/aws-sdk-s3/file_uploader.rb +11 -0
- data/lib/aws-sdk-s3/multipart_file_uploader.rb +37 -2
- data/lib/aws-sdk-s3/multipart_upload_part.rb +1 -1
- data/lib/aws-sdk-s3/object.rb +1 -1
- data/lib/aws-sdk-s3/object_summary.rb +19 -3
- data/lib/aws-sdk-s3/plugins/accelerate.rb +27 -38
- data/lib/aws-sdk-s3/plugins/dualstack.rb +3 -1
- data/lib/aws-sdk-s3/plugins/sse_cpk.rb +1 -1
- data/lib/aws-sdk-s3/presigned_post.rb +61 -28
- data/lib/aws-sdk-s3/presigner.rb +2 -2
- data/lib/aws-sdk-s3/resource.rb +1 -1
- data/lib/aws-sdk-s3/types.rb +25 -8
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 12869c75a61c6e62eb981846c9cac525962300fae8ca08cf87d5c6fde2824f5f
|
4
|
+
data.tar.gz: 6a29b43d4e3453c63ed50e7a18c06af16064e3db761dd2f784923bd20abba0c4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b331ecb2c04da30961f53906e6811ba52f6b2f5a74f1c32153a03d7c1900392a61c6a7af8b33daa296e1cc7632514a86b99ec6af6d4b1851b9379c9a3894221b
|
7
|
+
data.tar.gz: 61ef696b6a90673f1a89f3ac5d31ccc1e8f2350e8d492b67974a3861f9cfcfc1d509d81608d96d8ee68312e5462eb64f644b415fb5fd6f79d0587b272803b136
|
data/lib/aws-sdk-s3.rb
CHANGED
data/lib/aws-sdk-s3/bucket.rb
CHANGED
@@ -222,7 +222,7 @@ module Aws::S3
|
|
222
222
|
# bucket.create({
|
223
223
|
# acl: "private", # accepts private, public-read, public-read-write, authenticated-read
|
224
224
|
# create_bucket_configuration: {
|
225
|
-
# location_constraint: "
|
225
|
+
# location_constraint: "af-south-1", # accepts af-south-1, ap-east-1, ap-northeast-1, ap-northeast-2, ap-northeast-3, ap-south-1, ap-southeast-1, ap-southeast-2, ca-central-1, cn-north-1, cn-northwest-1, EU, eu-central-1, eu-north-1, eu-south-1, eu-west-1, eu-west-2, eu-west-3, me-south-1, sa-east-1, us-east-2, us-gov-east-1, us-gov-west-1, us-west-1, us-west-2
|
226
226
|
# },
|
227
227
|
# grant_full_control: "GrantFullControl",
|
228
228
|
# grant_read: "GrantRead",
|
@@ -357,7 +357,7 @@ module Aws::S3
|
|
357
357
|
#
|
358
358
|
#
|
359
359
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL
|
360
|
-
# @option options [String,
|
360
|
+
# @option options [String, StringIO, File] :body
|
361
361
|
# Object data.
|
362
362
|
# @option options [String] :cache_control
|
363
363
|
# Can be used to specify caching behavior along the request/reply chain.
|
data/lib/aws-sdk-s3/client.rb
CHANGED
@@ -335,7 +335,7 @@ module Aws::S3
|
|
335
335
|
# @option options [Boolean] :use_accelerate_endpoint (false)
|
336
336
|
# When set to `true`, accelerated bucket endpoints will be used
|
337
337
|
# for all object operations. You must first enable accelerate for
|
338
|
-
# each bucket.
|
338
|
+
# each bucket. [Go here for more information](http://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acceleration.html).
|
339
339
|
#
|
340
340
|
# @option options [Boolean] :use_dualstack_endpoint (false)
|
341
341
|
# When set to `true`, IPv6-compatible bucket endpoints will be used
|
@@ -529,7 +529,7 @@ module Aws::S3
|
|
529
529
|
# For information about permissions required to use the multipart upload
|
530
530
|
# API, see [Multipart Upload API and Permissions][3].
|
531
531
|
#
|
532
|
-
# `
|
532
|
+
# `CompleteMultipartUpload` has the following special errors:
|
533
533
|
#
|
534
534
|
# * Error code: `EntityTooSmall`
|
535
535
|
#
|
@@ -1290,7 +1290,7 @@ module Aws::S3
|
|
1290
1290
|
# acl: "private", # accepts private, public-read, public-read-write, authenticated-read
|
1291
1291
|
# bucket: "BucketName", # required
|
1292
1292
|
# create_bucket_configuration: {
|
1293
|
-
# location_constraint: "
|
1293
|
+
# location_constraint: "af-south-1", # accepts af-south-1, ap-east-1, ap-northeast-1, ap-northeast-2, ap-northeast-3, ap-south-1, ap-southeast-1, ap-southeast-2, ca-central-1, cn-north-1, cn-northwest-1, EU, eu-central-1, eu-north-1, eu-south-1, eu-west-1, eu-west-2, eu-west-3, me-south-1, sa-east-1, us-east-2, us-gov-east-1, us-gov-west-1, us-west-1, us-west-2
|
1294
1294
|
# },
|
1295
1295
|
# grant_full_control: "GrantFullControl",
|
1296
1296
|
# grant_read: "GrantRead",
|
@@ -2384,6 +2384,15 @@ module Aws::S3
|
|
2384
2384
|
# * {Types::DeleteObjectOutput#request_charged #request_charged} => String
|
2385
2385
|
#
|
2386
2386
|
#
|
2387
|
+
# @example Example: To delete an object (from a non-versioned bucket)
|
2388
|
+
#
|
2389
|
+
# # The following example deletes an object from a non-versioned bucket.
|
2390
|
+
#
|
2391
|
+
# resp = client.delete_object({
|
2392
|
+
# bucket: "ExampleBucket",
|
2393
|
+
# key: "HappyFace.jpg",
|
2394
|
+
# })
|
2395
|
+
#
|
2387
2396
|
# @example Example: To delete an object
|
2388
2397
|
#
|
2389
2398
|
# # The following example deletes an object from an S3 bucket.
|
@@ -2397,15 +2406,6 @@ module Aws::S3
|
|
2397
2406
|
# {
|
2398
2407
|
# }
|
2399
2408
|
#
|
2400
|
-
# @example Example: To delete an object (from a non-versioned bucket)
|
2401
|
-
#
|
2402
|
-
# # The following example deletes an object from a non-versioned bucket.
|
2403
|
-
#
|
2404
|
-
# resp = client.delete_object({
|
2405
|
-
# bucket: "ExampleBucket",
|
2406
|
-
# key: "HappyFace.jpg",
|
2407
|
-
# })
|
2408
|
-
#
|
2409
2409
|
# @example Request syntax with placeholder values
|
2410
2410
|
#
|
2411
2411
|
# resp = client.delete_object({
|
@@ -2469,7 +2469,7 @@ module Aws::S3
|
|
2469
2469
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-access-points.html
|
2470
2470
|
#
|
2471
2471
|
# @option params [required, String] :key
|
2472
|
-
# Name of the
|
2472
|
+
# Name of the object key.
|
2473
2473
|
#
|
2474
2474
|
# @option params [String] :version_id
|
2475
2475
|
# The versionId of the object that the tag-set will be removed from.
|
@@ -2479,35 +2479,35 @@ module Aws::S3
|
|
2479
2479
|
# * {Types::DeleteObjectTaggingOutput#version_id #version_id} => String
|
2480
2480
|
#
|
2481
2481
|
#
|
2482
|
-
# @example Example: To remove tag set from an object
|
2482
|
+
# @example Example: To remove tag set from an object
|
2483
2483
|
#
|
2484
|
-
# # The following example removes tag set associated with the specified object
|
2485
|
-
# #
|
2484
|
+
# # The following example removes tag set associated with the specified object. If the bucket is versioning enabled, the
|
2485
|
+
# # operation removes tag set from the latest object version.
|
2486
2486
|
#
|
2487
2487
|
# resp = client.delete_object_tagging({
|
2488
2488
|
# bucket: "examplebucket",
|
2489
2489
|
# key: "HappyFace.jpg",
|
2490
|
-
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
2491
2490
|
# })
|
2492
2491
|
#
|
2493
2492
|
# resp.to_h outputs the following:
|
2494
2493
|
# {
|
2495
|
-
# version_id: "
|
2494
|
+
# version_id: "null",
|
2496
2495
|
# }
|
2497
2496
|
#
|
2498
|
-
# @example Example: To remove tag set from an object
|
2497
|
+
# @example Example: To remove tag set from an object version
|
2499
2498
|
#
|
2500
|
-
# # The following example removes tag set associated with the specified object.
|
2501
|
-
# #
|
2499
|
+
# # The following example removes tag set associated with the specified object version. The request specifies both the
|
2500
|
+
# # object key and object version.
|
2502
2501
|
#
|
2503
2502
|
# resp = client.delete_object_tagging({
|
2504
2503
|
# bucket: "examplebucket",
|
2505
2504
|
# key: "HappyFace.jpg",
|
2505
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
2506
2506
|
# })
|
2507
2507
|
#
|
2508
2508
|
# resp.to_h outputs the following:
|
2509
2509
|
# {
|
2510
|
-
# version_id: "
|
2510
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
2511
2511
|
# }
|
2512
2512
|
#
|
2513
2513
|
# @example Request syntax with placeholder values
|
@@ -2626,22 +2626,20 @@ module Aws::S3
|
|
2626
2626
|
# * {Types::DeleteObjectsOutput#errors #errors} => Array<Types::Error>
|
2627
2627
|
#
|
2628
2628
|
#
|
2629
|
-
# @example Example: To delete multiple
|
2629
|
+
# @example Example: To delete multiple objects from a versioned bucket
|
2630
2630
|
#
|
2631
|
-
# # The following example deletes objects from a bucket. The
|
2632
|
-
# #
|
2631
|
+
# # The following example deletes objects from a bucket. The bucket is versioned, and the request does not specify the
|
2632
|
+
# # object version to delete. In this case, all versions remain in the bucket and S3 adds a delete marker.
|
2633
2633
|
#
|
2634
2634
|
# resp = client.delete_objects({
|
2635
2635
|
# bucket: "examplebucket",
|
2636
2636
|
# delete: {
|
2637
2637
|
# objects: [
|
2638
2638
|
# {
|
2639
|
-
# key: "
|
2640
|
-
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
2639
|
+
# key: "objectkey1",
|
2641
2640
|
# },
|
2642
2641
|
# {
|
2643
|
-
# key: "
|
2644
|
-
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
2642
|
+
# key: "objectkey2",
|
2645
2643
|
# },
|
2646
2644
|
# ],
|
2647
2645
|
# quiet: false,
|
@@ -2652,30 +2650,34 @@ module Aws::S3
|
|
2652
2650
|
# {
|
2653
2651
|
# deleted: [
|
2654
2652
|
# {
|
2655
|
-
#
|
2656
|
-
#
|
2653
|
+
# delete_marker: true,
|
2654
|
+
# delete_marker_version_id: "A._w1z6EFiCF5uhtQMDal9JDkID9tQ7F",
|
2655
|
+
# key: "objectkey1",
|
2657
2656
|
# },
|
2658
2657
|
# {
|
2659
|
-
#
|
2660
|
-
#
|
2658
|
+
# delete_marker: true,
|
2659
|
+
# delete_marker_version_id: "iOd_ORxhkKe_e8G8_oSGxt2PjsCZKlkt",
|
2660
|
+
# key: "objectkey2",
|
2661
2661
|
# },
|
2662
2662
|
# ],
|
2663
2663
|
# }
|
2664
2664
|
#
|
2665
|
-
# @example Example: To delete multiple
|
2665
|
+
# @example Example: To delete multiple object versions from a versioned bucket
|
2666
2666
|
#
|
2667
|
-
# # The following example deletes objects from a bucket. The
|
2668
|
-
# #
|
2667
|
+
# # The following example deletes objects from a bucket. The request specifies object versions. S3 deletes specific object
|
2668
|
+
# # versions and returns the key and versions of deleted objects in the response.
|
2669
2669
|
#
|
2670
2670
|
# resp = client.delete_objects({
|
2671
2671
|
# bucket: "examplebucket",
|
2672
2672
|
# delete: {
|
2673
2673
|
# objects: [
|
2674
2674
|
# {
|
2675
|
-
# key: "
|
2675
|
+
# key: "HappyFace.jpg",
|
2676
|
+
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
2676
2677
|
# },
|
2677
2678
|
# {
|
2678
|
-
# key: "
|
2679
|
+
# key: "HappyFace.jpg",
|
2680
|
+
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
2679
2681
|
# },
|
2680
2682
|
# ],
|
2681
2683
|
# quiet: false,
|
@@ -2686,14 +2688,12 @@ module Aws::S3
|
|
2686
2688
|
# {
|
2687
2689
|
# deleted: [
|
2688
2690
|
# {
|
2689
|
-
#
|
2690
|
-
#
|
2691
|
-
# key: "objectkey1",
|
2691
|
+
# key: "HappyFace.jpg",
|
2692
|
+
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
2692
2693
|
# },
|
2693
2694
|
# {
|
2694
|
-
#
|
2695
|
-
#
|
2696
|
-
# key: "objectkey2",
|
2695
|
+
# key: "HappyFace.jpg",
|
2696
|
+
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
2697
2697
|
# },
|
2698
2698
|
# ],
|
2699
2699
|
# }
|
@@ -3433,7 +3433,7 @@ module Aws::S3
|
|
3433
3433
|
#
|
3434
3434
|
# @example Response structure
|
3435
3435
|
#
|
3436
|
-
# resp.location_constraint #=> String, one of "
|
3436
|
+
# resp.location_constraint #=> String, one of "af-south-1", "ap-east-1", "ap-northeast-1", "ap-northeast-2", "ap-northeast-3", "ap-south-1", "ap-southeast-1", "ap-southeast-2", "ca-central-1", "cn-north-1", "cn-northwest-1", "EU", "eu-central-1", "eu-north-1", "eu-south-1", "eu-west-1", "eu-west-2", "eu-west-3", "me-south-1", "sa-east-1", "us-east-2", "us-gov-east-1", "us-gov-west-1", "us-west-1", "us-west-2"
|
3437
3437
|
#
|
3438
3438
|
# @see http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/GetBucketLocation AWS API Documentation
|
3439
3439
|
#
|
@@ -4522,49 +4522,49 @@ module Aws::S3
|
|
4522
4522
|
# * {Types::GetObjectOutput#object_lock_legal_hold_status #object_lock_legal_hold_status} => String
|
4523
4523
|
#
|
4524
4524
|
#
|
4525
|
-
# @example Example: To retrieve
|
4525
|
+
# @example Example: To retrieve an object
|
4526
4526
|
#
|
4527
|
-
# # The following example retrieves an object for an S3 bucket.
|
4528
|
-
# # specific byte range.
|
4527
|
+
# # The following example retrieves an object for an S3 bucket.
|
4529
4528
|
#
|
4530
4529
|
# resp = client.get_object({
|
4531
4530
|
# bucket: "examplebucket",
|
4532
|
-
# key: "
|
4533
|
-
# range: "bytes=0-9",
|
4531
|
+
# key: "HappyFace.jpg",
|
4534
4532
|
# })
|
4535
4533
|
#
|
4536
4534
|
# resp.to_h outputs the following:
|
4537
4535
|
# {
|
4538
4536
|
# accept_ranges: "bytes",
|
4539
|
-
# content_length:
|
4540
|
-
#
|
4541
|
-
#
|
4542
|
-
#
|
4543
|
-
# last_modified: Time.parse("Thu, 09 Oct 2014 22:57:28 GMT"),
|
4537
|
+
# content_length: 3191,
|
4538
|
+
# content_type: "image/jpeg",
|
4539
|
+
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
4540
|
+
# last_modified: Time.parse("Thu, 15 Dec 2016 01:19:41 GMT"),
|
4544
4541
|
# metadata: {
|
4545
4542
|
# },
|
4543
|
+
# tag_count: 2,
|
4546
4544
|
# version_id: "null",
|
4547
4545
|
# }
|
4548
4546
|
#
|
4549
|
-
# @example Example: To retrieve an object
|
4547
|
+
# @example Example: To retrieve a byte range of an object
|
4550
4548
|
#
|
4551
|
-
# # The following example retrieves an object for an S3 bucket.
|
4549
|
+
# # The following example retrieves an object for an S3 bucket. The request specifies the range header to retrieve a
|
4550
|
+
# # specific byte range.
|
4552
4551
|
#
|
4553
4552
|
# resp = client.get_object({
|
4554
4553
|
# bucket: "examplebucket",
|
4555
|
-
# key: "
|
4554
|
+
# key: "SampleFile.txt",
|
4555
|
+
# range: "bytes=0-9",
|
4556
4556
|
# })
|
4557
4557
|
#
|
4558
4558
|
# resp.to_h outputs the following:
|
4559
4559
|
# {
|
4560
4560
|
# accept_ranges: "bytes",
|
4561
|
-
# content_length:
|
4562
|
-
#
|
4563
|
-
#
|
4564
|
-
#
|
4561
|
+
# content_length: 10,
|
4562
|
+
# content_range: "bytes 0-9/43",
|
4563
|
+
# content_type: "text/plain",
|
4564
|
+
# etag: "\"0d94420ffd0bc68cd3d152506b97a9cc\"",
|
4565
|
+
# last_modified: Time.parse("Thu, 09 Oct 2014 22:57:28 GMT"),
|
4565
4566
|
# metadata: {
|
4566
4567
|
# },
|
4567
|
-
# tag_count: 2,
|
4568
4568
|
# version_id: "null",
|
4569
4569
|
# }
|
4570
4570
|
#
|
@@ -4589,8 +4589,10 @@ module Aws::S3
|
|
4589
4589
|
#
|
4590
4590
|
# @example Streaming data to a block
|
4591
4591
|
# # WARNING: yielding data to a block disables retries of networking errors
|
4592
|
+
# # However truncation of the body will be retried automatically using a range request
|
4592
4593
|
# File.open('/path/to/file', 'wb') do |file|
|
4593
|
-
# s3.get_object(bucket: 'bucket-name', key: 'object-key') do |chunk|
|
4594
|
+
# s3.get_object(bucket: 'bucket-name', key: 'object-key') do |chunk, headers|
|
4595
|
+
# # headers['content-length']
|
4594
4596
|
# file.write(chunk)
|
4595
4597
|
# end
|
4596
4598
|
# end
|
@@ -5032,49 +5034,49 @@ module Aws::S3
|
|
5032
5034
|
# * {Types::GetObjectTaggingOutput#tag_set #tag_set} => Array<Types::Tag>
|
5033
5035
|
#
|
5034
5036
|
#
|
5035
|
-
# @example Example: To retrieve tag set of
|
5037
|
+
# @example Example: To retrieve tag set of a specific object version
|
5036
5038
|
#
|
5037
|
-
# # The following example retrieves tag set of an object.
|
5039
|
+
# # The following example retrieves tag set of an object. The request specifies object version.
|
5038
5040
|
#
|
5039
5041
|
# resp = client.get_object_tagging({
|
5040
5042
|
# bucket: "examplebucket",
|
5041
|
-
# key: "
|
5043
|
+
# key: "exampleobject",
|
5044
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
5042
5045
|
# })
|
5043
5046
|
#
|
5044
5047
|
# resp.to_h outputs the following:
|
5045
5048
|
# {
|
5046
5049
|
# tag_set: [
|
5047
5050
|
# {
|
5048
|
-
# key: "
|
5049
|
-
# value: "
|
5050
|
-
# },
|
5051
|
-
# {
|
5052
|
-
# key: "Key3",
|
5053
|
-
# value: "Value3",
|
5051
|
+
# key: "Key1",
|
5052
|
+
# value: "Value1",
|
5054
5053
|
# },
|
5055
5054
|
# ],
|
5056
|
-
# version_id: "
|
5055
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
5057
5056
|
# }
|
5058
5057
|
#
|
5059
|
-
# @example Example: To retrieve tag set of
|
5058
|
+
# @example Example: To retrieve tag set of an object
|
5060
5059
|
#
|
5061
|
-
# # The following example retrieves tag set of an object.
|
5060
|
+
# # The following example retrieves tag set of an object.
|
5062
5061
|
#
|
5063
5062
|
# resp = client.get_object_tagging({
|
5064
5063
|
# bucket: "examplebucket",
|
5065
|
-
# key: "
|
5066
|
-
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
5064
|
+
# key: "HappyFace.jpg",
|
5067
5065
|
# })
|
5068
5066
|
#
|
5069
5067
|
# resp.to_h outputs the following:
|
5070
5068
|
# {
|
5071
5069
|
# tag_set: [
|
5072
5070
|
# {
|
5073
|
-
# key: "
|
5074
|
-
# value: "
|
5071
|
+
# key: "Key4",
|
5072
|
+
# value: "Value4",
|
5073
|
+
# },
|
5074
|
+
# {
|
5075
|
+
# key: "Key3",
|
5076
|
+
# value: "Value3",
|
5075
5077
|
# },
|
5076
5078
|
# ],
|
5077
|
-
# version_id: "
|
5079
|
+
# version_id: "null",
|
5078
5080
|
# }
|
5079
5081
|
#
|
5080
5082
|
# @example Request syntax with placeholder values
|
@@ -8470,6 +8472,17 @@ module Aws::S3
|
|
8470
8472
|
# configuration, you must also add the following elements:
|
8471
8473
|
# `DeleteMarkerReplication`, `Status`, and `Priority`.
|
8472
8474
|
#
|
8475
|
+
# <note markdown="1"> The latest version of the replication configuration XML is V2. XML V2
|
8476
|
+
# replication configurations are those that contain the `Filter` element
|
8477
|
+
# for rules, and rules that specify S3 Replication Time Control (S3
|
8478
|
+
# RTC). In XML V2 replication configurations, Amazon S3 doesn't
|
8479
|
+
# replicate delete markers. Therefore, you must set the
|
8480
|
+
# `DeleteMarkerReplication` element to `Disabled`. For backward
|
8481
|
+
# compatibility, Amazon S3 continues to support the XML V1 replication
|
8482
|
+
# configuration.
|
8483
|
+
#
|
8484
|
+
# </note>
|
8485
|
+
#
|
8473
8486
|
# For information about enabling versioning on a bucket, see [Using
|
8474
8487
|
# Versioning][3].
|
8475
8488
|
#
|
@@ -9162,7 +9175,7 @@ module Aws::S3
|
|
9162
9175
|
#
|
9163
9176
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL
|
9164
9177
|
#
|
9165
|
-
# @option params [String,
|
9178
|
+
# @option params [String, StringIO, File] :body
|
9166
9179
|
# Object data.
|
9167
9180
|
#
|
9168
9181
|
# @option params [required, String] :bucket
|
@@ -9380,24 +9393,39 @@ module Aws::S3
|
|
9380
9393
|
# * {Types::PutObjectOutput#request_charged #request_charged} => String
|
9381
9394
|
#
|
9382
9395
|
#
|
9383
|
-
# @example Example: To upload an object and specify
|
9396
|
+
# @example Example: To upload an object and specify canned ACL.
|
9384
9397
|
#
|
9385
|
-
# # The following example uploads and object. The request specifies
|
9386
|
-
# #
|
9398
|
+
# # The following example uploads and object. The request specifies optional canned ACL (access control list) to all READ
|
9399
|
+
# # access to authenticated users. If the bucket is versioning enabled, S3 returns version ID in response.
|
9387
9400
|
#
|
9388
9401
|
# resp = client.put_object({
|
9402
|
+
# acl: "authenticated-read",
|
9389
9403
|
# body: "filetoupload",
|
9390
9404
|
# bucket: "examplebucket",
|
9391
9405
|
# key: "exampleobject",
|
9392
|
-
# server_side_encryption: "AES256",
|
9393
|
-
# tagging: "key1=value1&key2=value2",
|
9394
9406
|
# })
|
9395
9407
|
#
|
9396
9408
|
# resp.to_h outputs the following:
|
9397
9409
|
# {
|
9398
9410
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
9399
|
-
#
|
9400
|
-
#
|
9411
|
+
# version_id: "Kirh.unyZwjQ69YxcQLA8z4F5j3kJJKr",
|
9412
|
+
# }
|
9413
|
+
#
|
9414
|
+
# @example Example: To upload an object
|
9415
|
+
#
|
9416
|
+
# # The following example uploads an object to a versioning-enabled bucket. The source file is specified using Windows file
|
9417
|
+
# # syntax. S3 returns VersionId of the newly created object.
|
9418
|
+
#
|
9419
|
+
# resp = client.put_object({
|
9420
|
+
# body: "HappyFace.jpg",
|
9421
|
+
# bucket: "examplebucket",
|
9422
|
+
# key: "HappyFace.jpg",
|
9423
|
+
# })
|
9424
|
+
#
|
9425
|
+
# resp.to_h outputs the following:
|
9426
|
+
# {
|
9427
|
+
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
9428
|
+
# version_id: "tpf3zF08nBplQK1XLOefGskR7mGDwcDk",
|
9401
9429
|
# }
|
9402
9430
|
#
|
9403
9431
|
# @example Example: To create an object.
|
@@ -9475,39 +9503,24 @@ module Aws::S3
|
|
9475
9503
|
# version_id: "pSKidl4pHBiNwukdbcPXAIs.sshFFOc0",
|
9476
9504
|
# }
|
9477
9505
|
#
|
9478
|
-
# @example Example: To upload an object and specify
|
9506
|
+
# @example Example: To upload an object and specify server-side encryption and object tags
|
9479
9507
|
#
|
9480
|
-
# # The following example uploads and object. The request specifies optional
|
9481
|
-
# #
|
9508
|
+
# # The following example uploads and object. The request specifies the optional server-side encryption option. The request
|
9509
|
+
# # also specifies optional object tags. If the bucket is versioning enabled, S3 returns version ID in response.
|
9482
9510
|
#
|
9483
9511
|
# resp = client.put_object({
|
9484
|
-
# acl: "authenticated-read",
|
9485
9512
|
# body: "filetoupload",
|
9486
9513
|
# bucket: "examplebucket",
|
9487
9514
|
# key: "exampleobject",
|
9515
|
+
# server_side_encryption: "AES256",
|
9516
|
+
# tagging: "key1=value1&key2=value2",
|
9488
9517
|
# })
|
9489
9518
|
#
|
9490
9519
|
# resp.to_h outputs the following:
|
9491
9520
|
# {
|
9492
9521
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
9493
|
-
#
|
9494
|
-
#
|
9495
|
-
#
|
9496
|
-
# @example Example: To upload an object
|
9497
|
-
#
|
9498
|
-
# # The following example uploads an object to a versioning-enabled bucket. The source file is specified using Windows file
|
9499
|
-
# # syntax. S3 returns VersionId of the newly created object.
|
9500
|
-
#
|
9501
|
-
# resp = client.put_object({
|
9502
|
-
# body: "HappyFace.jpg",
|
9503
|
-
# bucket: "examplebucket",
|
9504
|
-
# key: "HappyFace.jpg",
|
9505
|
-
# })
|
9506
|
-
#
|
9507
|
-
# resp.to_h outputs the following:
|
9508
|
-
# {
|
9509
|
-
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
9510
|
-
# version_id: "tpf3zF08nBplQK1XLOefGskR7mGDwcDk",
|
9522
|
+
# server_side_encryption: "AES256",
|
9523
|
+
# version_id: "Ri.vC6qVlA4dEnjgRV4ZHsHoFIjqEMNt",
|
9511
9524
|
# }
|
9512
9525
|
#
|
9513
9526
|
# @example Streaming a file from disk
|
@@ -10187,7 +10200,7 @@ module Aws::S3
|
|
10187
10200
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-access-points.html
|
10188
10201
|
#
|
10189
10202
|
# @option params [required, String] :key
|
10190
|
-
# Name of the
|
10203
|
+
# Name of the object key.
|
10191
10204
|
#
|
10192
10205
|
# @option params [String] :version_id
|
10193
10206
|
# The versionId of the object that the tag-set will be added to.
|
@@ -11238,7 +11251,7 @@ module Aws::S3
|
|
11238
11251
|
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html
|
11239
11252
|
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html
|
11240
11253
|
#
|
11241
|
-
# @option params [String,
|
11254
|
+
# @option params [String, StringIO, File] :body
|
11242
11255
|
# Object data.
|
11243
11256
|
#
|
11244
11257
|
# @option params [required, String] :bucket
|
@@ -11672,7 +11685,7 @@ module Aws::S3
|
|
11672
11685
|
params: params,
|
11673
11686
|
config: config)
|
11674
11687
|
context[:gem_name] = 'aws-sdk-s3'
|
11675
|
-
context[:gem_version] = '1.
|
11688
|
+
context[:gem_version] = '1.78.0'
|
11676
11689
|
Seahorse::Client::Request.new(handlers, context)
|
11677
11690
|
end
|
11678
11691
|
|