aws-sdk-s3 1.156.0 → 1.159.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/CHANGELOG.md +15 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-s3/access_grants_credentials_provider.rb +12 -3
- data/lib/aws-sdk-s3/bucket.rb +79 -16
- data/lib/aws-sdk-s3/client.rb +541 -312
- data/lib/aws-sdk-s3/client_api.rb +16 -1
- data/lib/aws-sdk-s3/multipart_upload.rb +20 -0
- data/lib/aws-sdk-s3/object.rb +36 -4
- data/lib/aws-sdk-s3/object_summary.rb +28 -0
- data/lib/aws-sdk-s3/object_version.rb +17 -4
- data/lib/aws-sdk-s3/plugins/access_grants.rb +68 -4
- data/lib/aws-sdk-s3/resource.rb +10 -8
- data/lib/aws-sdk-s3/types.rb +294 -47
- data/lib/aws-sdk-s3.rb +1 -1
- data/sig/bucket.rbs +1 -0
- data/sig/client.rbs +7 -1
- data/sig/multipart_upload.rbs +1 -0
- data/sig/object.rbs +1 -0
- data/sig/object_summary.rbs +1 -0
- data/sig/resource.rbs +2 -1
- data/sig/types.rbs +9 -0
- metadata +2 -2
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 63543f5716e2d34cc5f16260c094e5a1b74a9b81e4b1b48d25669cacaf636e53
         | 
| 4 | 
            +
              data.tar.gz: 9af48693b677847fcdd84c02864ff226205a19b47666e6da74b530d7f1d5833a
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 2d1f86f9df2fcfa8dec3afa9cab9c7a7773fecbdf758568a7c98b0c9c4bf758744d1c70a06db932c83a23fcfa2faced45e85a077e0c70af61c7b325892344819
         | 
| 7 | 
            +
              data.tar.gz: a896d4443f17aff9b4e1f1c5660fedcca5dac3c236e813f147de1e513c46e7fd15afad9ac7fa130e191e32bc072719f8a7a9db77603f0a236615361a4caac052
         | 
    
        data/CHANGELOG.md
    CHANGED
    
    | @@ -1,6 +1,21 @@ | |
| 1 1 | 
             
            Unreleased Changes
         | 
| 2 2 | 
             
            ------------------
         | 
| 3 3 |  | 
| 4 | 
            +
            1.159.0 (2024-08-20)
         | 
| 5 | 
            +
            ------------------
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            * Feature - Amazon Simple Storage Service / Features : Add support for conditional writes for PutObject and CompleteMultipartUpload APIs.
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            1.158.0 (2024-08-15)
         | 
| 10 | 
            +
            ------------------
         | 
| 11 | 
            +
             | 
| 12 | 
            +
            * Feature - Amazon Simple Storage Service / Features  : Adds support for pagination in the S3 ListBuckets API.
         | 
| 13 | 
            +
             | 
| 14 | 
            +
            1.157.0 (2024-08-01)
         | 
| 15 | 
            +
            ------------------
         | 
| 16 | 
            +
             | 
| 17 | 
            +
            * Feature - Support `head_bucket`, `get_object_attributes`, `delete_objects`, and `copy_object` for Access Grants.
         | 
| 18 | 
            +
             | 
| 4 19 | 
             
            1.156.0 (2024-07-02)
         | 
| 5 20 | 
             
            ------------------
         | 
| 6 21 |  | 
    
        data/VERSION
    CHANGED
    
    | @@ -1 +1 @@ | |
| 1 | 
            -
            1. | 
| 1 | 
            +
            1.159.0
         | 
| @@ -47,6 +47,8 @@ module Aws | |
| 47 47 | 
             
                    @caching = options.delete(:caching) != false
         | 
| 48 48 | 
             
                    @s3_control_clients = {}
         | 
| 49 49 | 
             
                    @bucket_region_cache = Aws::S3.bucket_region_cache
         | 
| 50 | 
            +
                    @head_bucket_mutex = Mutex.new
         | 
| 51 | 
            +
                    @head_bucket_call = false
         | 
| 50 52 | 
             
                    return unless @caching
         | 
| 51 53 |  | 
| 52 54 | 
             
                    @credentials_cache = Aws::S3.access_grants_credentials_cache
         | 
| @@ -195,9 +197,16 @@ module Aws | |
| 195 197 | 
             
                  end
         | 
| 196 198 |  | 
| 197 199 | 
             
                  def new_bucket_region_for(bucket)
         | 
| 198 | 
            -
                    @ | 
| 199 | 
            -
             | 
| 200 | 
            -
             | 
| 200 | 
            +
                    @head_bucket_mutex.synchronize do
         | 
| 201 | 
            +
                      begin
         | 
| 202 | 
            +
                        @head_bucket_call = true
         | 
| 203 | 
            +
                        @s3_client.head_bucket(bucket: bucket).bucket_region
         | 
| 204 | 
            +
                      rescue Aws::S3::Errors::Http301Error => e
         | 
| 205 | 
            +
                        e.data.region
         | 
| 206 | 
            +
                      ensure
         | 
| 207 | 
            +
                        @head_bucket_call = false
         | 
| 208 | 
            +
                      end
         | 
| 209 | 
            +
                    end
         | 
| 201 210 | 
             
                  end
         | 
| 202 211 |  | 
| 203 212 | 
             
                  # returns the account id for the configured credentials
         | 
    
        data/lib/aws-sdk-s3/bucket.rb
    CHANGED
    
    | @@ -497,6 +497,7 @@ module Aws::S3 | |
| 497 497 | 
             
                #     checksum_sha1: "ChecksumSHA1",
         | 
| 498 498 | 
             
                #     checksum_sha256: "ChecksumSHA256",
         | 
| 499 499 | 
             
                #     expires: Time.now,
         | 
| 500 | 
            +
                #     if_none_match: "IfNoneMatch",
         | 
| 500 501 | 
             
                #     grant_full_control: "GrantFullControl",
         | 
| 501 502 | 
             
                #     grant_read: "GrantRead",
         | 
| 502 503 | 
             
                #     grant_read_acp: "GrantReadACP",
         | 
| @@ -712,6 +713,24 @@ module Aws::S3 | |
| 712 713 | 
             
                #
         | 
| 713 714 | 
             
                #
         | 
| 714 715 | 
             
                #   [1]: https://www.rfc-editor.org/rfc/rfc7234#section-5.3
         | 
| 716 | 
            +
                # @option options [String] :if_none_match
         | 
| 717 | 
            +
                #   Uploads the object only if the object key name does not already exist
         | 
| 718 | 
            +
                #   in the bucket specified. Otherwise, Amazon S3 returns a `412
         | 
| 719 | 
            +
                #   Precondition Failed` error.
         | 
| 720 | 
            +
                #
         | 
| 721 | 
            +
                #   If a conflicting operation occurs during the upload S3 returns a `409
         | 
| 722 | 
            +
                #   ConditionalRequestConflict` response. On a 409 failure you should
         | 
| 723 | 
            +
                #   retry the upload.
         | 
| 724 | 
            +
                #
         | 
| 725 | 
            +
                #   Expects the '*' (asterisk) character.
         | 
| 726 | 
            +
                #
         | 
| 727 | 
            +
                #   For more information about conditional requests, see [RFC 7232][1], or
         | 
| 728 | 
            +
                #   [Conditional requests][2] in the *Amazon S3 User Guide*.
         | 
| 729 | 
            +
                #
         | 
| 730 | 
            +
                #
         | 
| 731 | 
            +
                #
         | 
| 732 | 
            +
                #   [1]: https://tools.ietf.org/html/rfc7232
         | 
| 733 | 
            +
                #   [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html
         | 
| 715 734 | 
             
                # @option options [String] :grant_full_control
         | 
| 716 735 | 
             
                #   Gives the grantee READ, READ\_ACP, and WRITE\_ACP permissions on the
         | 
| 717 736 | 
             
                #   object.
         | 
| @@ -1018,12 +1037,26 @@ module Aws::S3 | |
| 1018 1037 | 
             
                #
         | 
| 1019 1038 | 
             
                #    </note>
         | 
| 1020 1039 | 
             
                # @option options [String] :encoding_type
         | 
| 1021 | 
            -
                #    | 
| 1022 | 
            -
                #    | 
| 1023 | 
            -
                #   Unicode character | 
| 1024 | 
            -
                #   characters, such as characters with an ASCII value from | 
| 1025 | 
            -
                #   characters that  | 
| 1026 | 
            -
                #   parameter to request that Amazon S3 encode the keys in the | 
| 1040 | 
            +
                #   Encoding type used by Amazon S3 to encode the [object keys][1] in the
         | 
| 1041 | 
            +
                #   response. Responses are encoded only in UTF-8. An object key can
         | 
| 1042 | 
            +
                #   contain any Unicode character. However, the XML 1.0 parser can't
         | 
| 1043 | 
            +
                #   parse certain characters, such as characters with an ASCII value from
         | 
| 1044 | 
            +
                #   0 to 10. For characters that aren't supported in XML 1.0, you can add
         | 
| 1045 | 
            +
                #   this parameter to request that Amazon S3 encode the keys in the
         | 
| 1046 | 
            +
                #   response. For more information about characters to avoid in object key
         | 
| 1047 | 
            +
                #   names, see [Object key naming guidelines][2].
         | 
| 1048 | 
            +
                #
         | 
| 1049 | 
            +
                #   <note markdown="1"> When using the URL encoding type, non-ASCII characters that are used
         | 
| 1050 | 
            +
                #   in an object's key name will be percent-encoded according to UTF-8
         | 
| 1051 | 
            +
                #   code values. For example, the object `test_file(3).png` will appear as
         | 
| 1052 | 
            +
                #   `test_file%283%29.png`.
         | 
| 1053 | 
            +
                #
         | 
| 1054 | 
            +
                #    </note>
         | 
| 1055 | 
            +
                #
         | 
| 1056 | 
            +
                #
         | 
| 1057 | 
            +
                #
         | 
| 1058 | 
            +
                #   [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html
         | 
| 1059 | 
            +
                #   [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines
         | 
| 1027 1060 | 
             
                # @option options [String] :key_marker
         | 
| 1028 1061 | 
             
                #   Specifies the multipart upload after which listing should begin.
         | 
| 1029 1062 | 
             
                #
         | 
| @@ -1156,12 +1189,26 @@ module Aws::S3 | |
| 1156 1189 | 
             
                #   the `max-keys` limitation. These keys are not returned elsewhere in
         | 
| 1157 1190 | 
             
                #   the response.
         | 
| 1158 1191 | 
             
                # @option options [String] :encoding_type
         | 
| 1159 | 
            -
                #    | 
| 1160 | 
            -
                #    | 
| 1161 | 
            -
                #   Unicode character | 
| 1162 | 
            -
                #   characters, such as characters with an ASCII value from | 
| 1163 | 
            -
                #   characters that  | 
| 1164 | 
            -
                #   parameter to request that Amazon S3 encode the keys in the | 
| 1192 | 
            +
                #   Encoding type used by Amazon S3 to encode the [object keys][1] in the
         | 
| 1193 | 
            +
                #   response. Responses are encoded only in UTF-8. An object key can
         | 
| 1194 | 
            +
                #   contain any Unicode character. However, the XML 1.0 parser can't
         | 
| 1195 | 
            +
                #   parse certain characters, such as characters with an ASCII value from
         | 
| 1196 | 
            +
                #   0 to 10. For characters that aren't supported in XML 1.0, you can add
         | 
| 1197 | 
            +
                #   this parameter to request that Amazon S3 encode the keys in the
         | 
| 1198 | 
            +
                #   response. For more information about characters to avoid in object key
         | 
| 1199 | 
            +
                #   names, see [Object key naming guidelines][2].
         | 
| 1200 | 
            +
                #
         | 
| 1201 | 
            +
                #   <note markdown="1"> When using the URL encoding type, non-ASCII characters that are used
         | 
| 1202 | 
            +
                #   in an object's key name will be percent-encoded according to UTF-8
         | 
| 1203 | 
            +
                #   code values. For example, the object `test_file(3).png` will appear as
         | 
| 1204 | 
            +
                #   `test_file%283%29.png`.
         | 
| 1205 | 
            +
                #
         | 
| 1206 | 
            +
                #    </note>
         | 
| 1207 | 
            +
                #
         | 
| 1208 | 
            +
                #
         | 
| 1209 | 
            +
                #
         | 
| 1210 | 
            +
                #   [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html
         | 
| 1211 | 
            +
                #   [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines
         | 
| 1165 1212 | 
             
                # @option options [String] :key_marker
         | 
| 1166 1213 | 
             
                #   Specifies the key to start with when listing objects in a bucket.
         | 
| 1167 1214 | 
             
                # @option options [String] :prefix
         | 
| @@ -1252,10 +1299,26 @@ module Aws::S3 | |
| 1252 1299 | 
             
                #
         | 
| 1253 1300 | 
             
                #   [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html
         | 
| 1254 1301 | 
             
                # @option options [String] :encoding_type
         | 
| 1255 | 
            -
                #   Encoding type used by Amazon S3 to encode object keys in the | 
| 1256 | 
            -
                #    | 
| 1257 | 
            -
                #    | 
| 1258 | 
            -
                #    | 
| 1302 | 
            +
                #   Encoding type used by Amazon S3 to encode the [object keys][1] in the
         | 
| 1303 | 
            +
                #   response. Responses are encoded only in UTF-8. An object key can
         | 
| 1304 | 
            +
                #   contain any Unicode character. However, the XML 1.0 parser can't
         | 
| 1305 | 
            +
                #   parse certain characters, such as characters with an ASCII value from
         | 
| 1306 | 
            +
                #   0 to 10. For characters that aren't supported in XML 1.0, you can add
         | 
| 1307 | 
            +
                #   this parameter to request that Amazon S3 encode the keys in the
         | 
| 1308 | 
            +
                #   response. For more information about characters to avoid in object key
         | 
| 1309 | 
            +
                #   names, see [Object key naming guidelines][2].
         | 
| 1310 | 
            +
                #
         | 
| 1311 | 
            +
                #   <note markdown="1"> When using the URL encoding type, non-ASCII characters that are used
         | 
| 1312 | 
            +
                #   in an object's key name will be percent-encoded according to UTF-8
         | 
| 1313 | 
            +
                #   code values. For example, the object `test_file(3).png` will appear as
         | 
| 1314 | 
            +
                #   `test_file%283%29.png`.
         | 
| 1315 | 
            +
                #
         | 
| 1316 | 
            +
                #    </note>
         | 
| 1317 | 
            +
                #
         | 
| 1318 | 
            +
                #
         | 
| 1319 | 
            +
                #
         | 
| 1320 | 
            +
                #   [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html
         | 
| 1321 | 
            +
                #   [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines
         | 
| 1259 1322 | 
             
                # @option options [String] :prefix
         | 
| 1260 1323 | 
             
                #   Limits the response to keys that begin with the specified prefix.
         | 
| 1261 1324 | 
             
                #
         |