aws-sdk-s3 1.93.1 → 1.94.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-s3.rb +1 -1
- data/lib/aws-sdk-s3/client.rb +1 -1
- data/lib/aws-sdk-s3/customizations/object.rb +30 -11
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '094e61334fb27d9edd1666450c6a08902d650f172c03285254bffb967b9fa9ab'
|
4
|
+
data.tar.gz: f864356a00540fac9606874ef3d754448354e9353a73ef8d337718534e218e1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e6355b5f02d3b3d68fbcb8c75787a767044dec23c1997ae0b3706d65faabf1a3fade04c951e042b4ae9528f4e4f9b113ba71ae0fbca3da69b09b632db5d887d0
|
7
|
+
data.tar.gz: da2145f461223e7a53e15f3760a80f474add0024936798e0667b74642d57eee109e88f0fa067f7c24c8db5e31d8d3ac474cb2649ba44072523b4a1b617ce7379
|
data/CHANGELOG.md
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.94.0
|
data/lib/aws-sdk-s3.rb
CHANGED
data/lib/aws-sdk-s3/client.rb
CHANGED
@@ -13910,7 +13910,7 @@ module Aws::S3
|
|
13910
13910
|
params: params,
|
13911
13911
|
config: config)
|
13912
13912
|
context[:gem_name] = 'aws-sdk-s3'
|
13913
|
-
context[:gem_version] = '1.
|
13913
|
+
context[:gem_version] = '1.94.0'
|
13914
13914
|
Seahorse::Client::Request.new(handlers, context)
|
13915
13915
|
end
|
13916
13916
|
|
@@ -153,21 +153,35 @@ module Aws
|
|
153
153
|
# obj.presigned_url(:put, acl: 'public-read')
|
154
154
|
# #=> "https://bucket-name.s3.amazonaws.com/object-key?..."
|
155
155
|
#
|
156
|
-
# @
|
157
|
-
#
|
158
|
-
#
|
156
|
+
# @example Pre-signed UploadPart PUT
|
157
|
+
#
|
158
|
+
# # the object uploaded using this URL will be publicly accessible
|
159
|
+
# obj.presigned_url(:upload_part, part_number: 1, upload_id: 'uploadIdToken')
|
160
|
+
# #=> "https://bucket-name.s3.amazonaws.com/object-key?..."
|
161
|
+
#
|
162
|
+
# @param [Symbol] method
|
163
|
+
# The S3 operation to generate a presigned URL for. Valid values
|
164
|
+
# are `:get`, `:put`, `:head`, `:delete`, `:create_multipart_upload`,
|
165
|
+
# `:list_multipart_uploads`, `:complete_multipart_upload`,
|
166
|
+
# `:abort_multipart_upload`, `:list_parts`, and `:upload_part`.
|
159
167
|
#
|
160
168
|
# @param [Hash] params
|
161
169
|
# Additional request parameters to use when generating the pre-signed
|
162
170
|
# URL. See the related documentation in {Client} for accepted
|
163
171
|
# params.
|
164
172
|
#
|
165
|
-
# |
|
166
|
-
#
|
167
|
-
# | `:get`
|
168
|
-
# | `:put`
|
169
|
-
# | `:head`
|
170
|
-
# | `:delete`
|
173
|
+
# | Method | Client Method |
|
174
|
+
# |------------------------------|------------------------------------|
|
175
|
+
# | `:get` | {Client#get_object} |
|
176
|
+
# | `:put` | {Client#put_object} |
|
177
|
+
# | `:head` | {Client#head_object} |
|
178
|
+
# | `:delete` | {Client#delete_object} |
|
179
|
+
# | `:create_multipart_upload` | {Client#create_multipart_upload} |
|
180
|
+
# | `:list_multipart_uploads` | {Client#list_multipart_uploads} |
|
181
|
+
# | `:complete_multipart_upload` | {Client#complete_multipart_upload} |
|
182
|
+
# | `:abort_multipart_upload` | {Client#abort_multipart_upload} |
|
183
|
+
# | `:list_parts` | {Client#list_parts} |
|
184
|
+
# | `:upload_part` | {Client#upload_part} |
|
171
185
|
#
|
172
186
|
# @option params [Boolean] :virtual_host (false) When `true` the
|
173
187
|
# presigned URL will use the bucket name as a virtual host.
|
@@ -188,10 +202,15 @@ module Aws
|
|
188
202
|
#
|
189
203
|
# @return [String]
|
190
204
|
#
|
191
|
-
def presigned_url(
|
205
|
+
def presigned_url(method, params = {})
|
192
206
|
presigner = Presigner.new(client: client)
|
207
|
+
|
208
|
+
if %w(delete head get put).include?(method.to_s)
|
209
|
+
method = "#{method}_object".to_sym
|
210
|
+
end
|
211
|
+
|
193
212
|
presigner.presigned_url(
|
194
|
-
|
213
|
+
method.downcase,
|
195
214
|
params.merge(bucket: bucket_name, key: key)
|
196
215
|
)
|
197
216
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk-s3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.94.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Amazon Web Services
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-04-
|
11
|
+
date: 2021-04-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-kms
|
@@ -183,8 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
183
183
|
- !ruby/object:Gem::Version
|
184
184
|
version: '0'
|
185
185
|
requirements: []
|
186
|
-
|
187
|
-
rubygems_version: 2.7.6.2
|
186
|
+
rubygems_version: 3.1.6
|
188
187
|
signing_key:
|
189
188
|
specification_version: 4
|
190
189
|
summary: AWS SDK for Ruby - Amazon S3
|