aws-sdk 1.31.3 → 1.32.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE.txt +1 -1
- data/lib/aws/api_config/AutoScaling-2011-01-01.yml +27 -1
- data/lib/aws/api_config/Glacier-2012-06-01.yml +32 -1
- data/lib/aws/api_config/Support-2013-04-15.yml +1 -3
- data/lib/aws/cloud_formation/stack_collection.rb +14 -5
- data/lib/aws/core/signers/base.rb +1 -1
- data/lib/aws/core/signers/version_4.rb +1 -1
- data/lib/aws/core/signers/version_4/chunk_signed_stream.rb +1 -1
- data/lib/aws/ec2.rb +0 -1
- data/lib/aws/ec2/client.rb +7 -3
- data/lib/aws/ec2/config.rb +12 -0
- data/lib/aws/glacier/archive_collection.rb +3 -3
- data/lib/aws/import_export/client.rb +1 -1
- data/lib/aws/s3/bucket_collection.rb +1 -1
- data/lib/aws/s3/bucket_version_collection.rb +3 -1
- data/lib/aws/s3/multipart_upload.rb +7 -0
- data/lib/aws/s3/multipart_upload_collection.rb +6 -0
- data/lib/aws/s3/object_version.rb +6 -0
- data/lib/aws/s3/s3_object.rb +7 -0
- data/lib/aws/version.rb +1 -1
- metadata +2 -3
- data/lib/aws/ec2/config_transform.rb +0 -63
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4ae66f6230e1369795f201c43774b7f9dd9532f6
|
4
|
+
data.tar.gz: deb83556fe23fc04b33b682558b00e1f73d1b776
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: da5974b284fa7071253e97ae674fb27006736bcaa8777ee0b4462c751245747c02705ce6f94879a3219ce8722002191cc9c1af49c2dfb251847304e4c2ca57af
|
7
|
+
data.tar.gz: de9a6d3e942d01cb7185c6c54e64189775470c1a2307bc18260ec3ad8f988d56e7e4dfcc2c55d454cfac9dbdad583334ceefb9dc03855e16ff1d831c6252d5ad
|
data/LICENSE.txt
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
Copyright 2011-
|
1
|
+
Copyright 2011-2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2
2
|
|
3
3
|
Licensed under the Apache License, Version 2.0 (the "License"). You
|
4
4
|
may not use this file except in compliance with the License. A copy of
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright 2011-
|
1
|
+
# Copyright 2011-2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2
2
|
#
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License"). You
|
4
4
|
# may not use this file except in compliance with the License. A copy of
|
@@ -119,6 +119,14 @@
|
|
119
119
|
- :string
|
120
120
|
VolumeSize:
|
121
121
|
- :integer
|
122
|
+
VolumeType:
|
123
|
+
- :string
|
124
|
+
DeleteOnTermination:
|
125
|
+
- :boolean
|
126
|
+
Iops:
|
127
|
+
- :integer
|
128
|
+
NoDevice:
|
129
|
+
- :boolean
|
122
130
|
InstanceMonitoring:
|
123
131
|
- :structure:
|
124
132
|
Enabled:
|
@@ -238,6 +246,18 @@
|
|
238
246
|
:children:
|
239
247
|
DeleteTagsResult:
|
240
248
|
:ignore: true
|
249
|
+
- :name: DescribeAccountLimits
|
250
|
+
:method: :describe_account_limits
|
251
|
+
:inputs: {}
|
252
|
+
:outputs:
|
253
|
+
:children:
|
254
|
+
DescribeAccountLimitsResult:
|
255
|
+
:ignore: true
|
256
|
+
:children:
|
257
|
+
MaxNumberOfAutoScalingGroups:
|
258
|
+
:type: :integer
|
259
|
+
MaxNumberOfLaunchConfigurations:
|
260
|
+
:type: :integer
|
241
261
|
- :name: DescribeAdjustmentTypes
|
242
262
|
:method: :describe_adjustment_types
|
243
263
|
:inputs: {}
|
@@ -405,6 +425,12 @@
|
|
405
425
|
:children:
|
406
426
|
VolumeSize:
|
407
427
|
:type: :integer
|
428
|
+
DeleteOnTermination:
|
429
|
+
:type: :boolean
|
430
|
+
Iops:
|
431
|
+
:type: :integer
|
432
|
+
NoDevice:
|
433
|
+
:type: :boolean
|
408
434
|
InstanceMonitoring:
|
409
435
|
:children:
|
410
436
|
Enabled:
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright 2011-
|
1
|
+
# Copyright 2011-2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2
2
|
#
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License"). You
|
4
4
|
# may not use this file except in compliance with the License. A copy of
|
@@ -182,6 +182,12 @@
|
|
182
182
|
SHA256TreeHash:
|
183
183
|
:sym: :sha256_tree_hash
|
184
184
|
:type: :string
|
185
|
+
ArchiveSHA256TreeHash:
|
186
|
+
:sym: :archive_sha256_tree_hash
|
187
|
+
:type: :string
|
188
|
+
RetrievalByteRange:
|
189
|
+
:sym: :retrieval_byte_range
|
190
|
+
:type: :string
|
185
191
|
- :name: DescribeVault
|
186
192
|
:method: :describe_vault
|
187
193
|
:http:
|
@@ -297,6 +303,25 @@
|
|
297
303
|
:sns_topic:
|
298
304
|
:name: SNSTopic
|
299
305
|
:type: :string
|
306
|
+
:retrieval_byte_range:
|
307
|
+
:name: RetrievalByteRange
|
308
|
+
:type: :string
|
309
|
+
:inventory_retrieval_parameters:
|
310
|
+
:name: InventoryRetrievalParameters
|
311
|
+
:type: :hash
|
312
|
+
:members:
|
313
|
+
:start_date:
|
314
|
+
:name: StartDate
|
315
|
+
:type: :string
|
316
|
+
:end_date:
|
317
|
+
:name: EndDate
|
318
|
+
:type: :string
|
319
|
+
:limit:
|
320
|
+
:name: Limit
|
321
|
+
:type: :string
|
322
|
+
:marker:
|
323
|
+
:name: Marker
|
324
|
+
:type: :string
|
300
325
|
:outputs: {}
|
301
326
|
- :name: InitiateMultipartUpload
|
302
327
|
:method: :initiate_multipart_upload
|
@@ -389,6 +414,12 @@
|
|
389
414
|
SHA256TreeHash:
|
390
415
|
:sym: :sha256_tree_hash
|
391
416
|
:type: :string
|
417
|
+
ArchiveSHA256TreeHash:
|
418
|
+
:sym: :archive_sha256_tree_hash
|
419
|
+
:type: :string
|
420
|
+
RetrievalByteRange:
|
421
|
+
:sym: :retrieval_byte_range
|
422
|
+
:type: :string
|
392
423
|
Marker:
|
393
424
|
:sym: :marker
|
394
425
|
:type: :string
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright 2011-
|
1
|
+
# Copyright 2011-2014 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2
2
|
#
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License"). You
|
4
4
|
# may not use this file except in compliance with the License. A copy of
|
@@ -39,12 +39,10 @@
|
|
39
39
|
- :required
|
40
40
|
serviceCode:
|
41
41
|
- :string
|
42
|
-
- :required
|
43
42
|
severityCode:
|
44
43
|
- :string
|
45
44
|
categoryCode:
|
46
45
|
- :string
|
47
|
-
- :required
|
48
46
|
communicationBody:
|
49
47
|
- :string
|
50
48
|
- :required
|
@@ -159,7 +159,17 @@ module AWS
|
|
159
159
|
# puts stack.name
|
160
160
|
# end
|
161
161
|
#
|
162
|
-
#
|
162
|
+
# You can provide multiple statuses:
|
163
|
+
#
|
164
|
+
# statuses = [:create_failed, :rollback_failed]
|
165
|
+
# cloud_formation.stacks.with_status(statuses).each do |stack|
|
166
|
+
# puts stack.name
|
167
|
+
# end
|
168
|
+
#
|
169
|
+
# Status names may be symbolized (snake-cased) or upper-cased strings
|
170
|
+
# (e.g. :create_in_progress, 'CREATE_IN_PROGRESS').
|
171
|
+
#
|
172
|
+
# @param [Symbol,String] status_filters A status to filter stacks with.
|
163
173
|
# Valid values include:
|
164
174
|
#
|
165
175
|
# * `:create_in_progress`
|
@@ -182,10 +192,9 @@ module AWS
|
|
182
192
|
# @return [StackCollection] Returns a new stack collection that
|
183
193
|
# filters the stacks returned by the given status.
|
184
194
|
#
|
185
|
-
def with_status
|
186
|
-
|
187
|
-
|
188
|
-
:config => config)
|
195
|
+
def with_status *status_filters
|
196
|
+
filters = @status_filters + status_filters.flatten.map(&:to_s).map(&:upcase)
|
197
|
+
StackCollection.new(:status_filters => filters, :config => config)
|
189
198
|
end
|
190
199
|
|
191
200
|
protected
|
@@ -36,7 +36,7 @@ module AWS
|
|
36
36
|
# @param [String] digest ('sha256')
|
37
37
|
# @return [String]
|
38
38
|
def hmac key, value, digest = 'sha256'
|
39
|
-
OpenSSL::HMAC.digest(OpenSSL::Digest
|
39
|
+
OpenSSL::HMAC.digest(OpenSSL::Digest.new(digest), key, value)
|
40
40
|
end
|
41
41
|
module_function :hmac
|
42
42
|
|
data/lib/aws/ec2.rb
CHANGED
@@ -231,7 +231,6 @@ module AWS
|
|
231
231
|
autoload :BlockDeviceMappings, 'aws/ec2/block_device_mappings'
|
232
232
|
autoload :Client, 'aws/ec2/client'
|
233
233
|
autoload :Collection, 'aws/ec2/collection'
|
234
|
-
autoload :ConfigTransform, 'aws/ec2/config_transform'
|
235
234
|
autoload :CustomerGateway, 'aws/ec2/customer_gateway'
|
236
235
|
autoload :CustomerGatewayCollection, 'aws/ec2/customer_gateway_collection'
|
237
236
|
autoload :DHCPOptions, 'aws/ec2/dhcp_options'
|
data/lib/aws/ec2/client.rb
CHANGED
@@ -20,10 +20,14 @@ module AWS
|
|
20
20
|
API_VERSION = '2013-10-15'
|
21
21
|
|
22
22
|
def sign_request request
|
23
|
-
|
24
|
-
|
23
|
+
version = @config.ec2_signature_version ?
|
24
|
+
@config.ec2_signature_version.to_sym :
|
25
|
+
(@region =~ /cn-/ ? :v4 : :v2)
|
26
|
+
case version
|
27
|
+
when :v4 then v4_signer.sign_request(request)
|
28
|
+
when :v2 then v2_signer.sign_request(request)
|
25
29
|
else
|
26
|
-
|
30
|
+
raise "invalid signature version #{version.inspect}"
|
27
31
|
end
|
28
32
|
end
|
29
33
|
|
data/lib/aws/ec2/config.rb
CHANGED
@@ -15,4 +15,16 @@ AWS::Core::Configuration.module_eval do
|
|
15
15
|
|
16
16
|
add_service 'EC2', 'ec2', 'ec2'
|
17
17
|
|
18
|
+
add_option :ec2_signature_version do |config, value|
|
19
|
+
if config.ec2_region.match(/^cn-/)
|
20
|
+
:v4
|
21
|
+
elsif value
|
22
|
+
value
|
23
|
+
elsif config.ec2 && config.ec2[:signature_version]
|
24
|
+
config.ec2[:signature_version]
|
25
|
+
else
|
26
|
+
:v2
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
18
30
|
end
|
@@ -101,8 +101,8 @@ module AWS
|
|
101
101
|
# but that requires reading the data a 2nd time. :(
|
102
102
|
def compute_checksums data
|
103
103
|
|
104
|
-
digest = OpenSSL::Digest
|
105
|
-
tree_digest = OpenSSL::Digest
|
104
|
+
digest = OpenSSL::Digest.new('sha256')
|
105
|
+
tree_digest = OpenSSL::Digest.new('sha256')
|
106
106
|
tree_parts = []
|
107
107
|
|
108
108
|
until data.eof?
|
@@ -123,7 +123,7 @@ module AWS
|
|
123
123
|
|
124
124
|
def compute_tree_hash hashes
|
125
125
|
|
126
|
-
digest = OpenSSL::Digest
|
126
|
+
digest = OpenSSL::Digest.new('sha256')
|
127
127
|
|
128
128
|
until hashes.count == 1
|
129
129
|
hashes = hashes.each_slice(2).map do |h1,h2|
|
@@ -53,7 +53,9 @@ module AWS
|
|
53
53
|
super
|
54
54
|
page.versions.each do |version|
|
55
55
|
object_version = ObjectVersion.new(bucket.objects[version.key],
|
56
|
-
|
56
|
+
version.version_id,
|
57
|
+
:delete_marker => version.delete_marker?,
|
58
|
+
:last_modified => version.last_modified)
|
57
59
|
yield(object_version)
|
58
60
|
end
|
59
61
|
end
|
@@ -19,6 +19,13 @@ module AWS
|
|
19
19
|
# Represents a multipart upload to an S3 object. See
|
20
20
|
# {S3Object#multipart_upload} for a convenient way to initiate a
|
21
21
|
# multipart upload.
|
22
|
+
#
|
23
|
+
# Note: After you initiate multipart upload and upload one or more
|
24
|
+
# parts, you must either complete or abort multipart upload in order
|
25
|
+
# to stop getting charged for storage of the uploaded parts. Only
|
26
|
+
# after you either complete or abort multipart upload, Amazon S3
|
27
|
+
# frees up the parts storage and stops charging you for the parts
|
28
|
+
# storage.
|
22
29
|
class MultipartUpload
|
23
30
|
|
24
31
|
include Core::Model
|
@@ -16,6 +16,12 @@ module AWS
|
|
16
16
|
|
17
17
|
# Represents the uploads in progress for a bucket.
|
18
18
|
#
|
19
|
+
# Note: After you initiate multipart upload and upload one or more
|
20
|
+
# parts, you must either complete or abort multipart upload in order
|
21
|
+
# to stop getting charged for storage of the uploaded parts. Only
|
22
|
+
# after you either complete or abort multipart upload, Amazon S3 frees
|
23
|
+
# up the parts storage and stops charging you for the parts storage.
|
24
|
+
#
|
19
25
|
# @example Finding uploads by prefix
|
20
26
|
#
|
21
27
|
# bucket.multipart_uploads.with_prefix("photos/").
|
@@ -28,16 +28,22 @@ module AWS
|
|
28
28
|
# @param [Hash] options
|
29
29
|
# @option options [Boolean] :delete_marker Is this version a
|
30
30
|
# delete marker?
|
31
|
+
# @option options [DateTime] :last_modified Date and time the
|
32
|
+
# object was last modified.
|
31
33
|
def initialize(object, version_id, options = {})
|
32
34
|
@object = object
|
33
35
|
@version_id = version_id
|
34
36
|
@delete_marker = options[:delete_marker]
|
37
|
+
@last_modified = options[:last_modified]
|
35
38
|
super
|
36
39
|
end
|
37
40
|
|
38
41
|
# @return [S3Object] the object this is a version of.
|
39
42
|
attr_reader :object
|
40
43
|
|
44
|
+
# @return [DateTime] timestamp of this version
|
45
|
+
attr_reader :last_modified
|
46
|
+
|
41
47
|
def bucket
|
42
48
|
object.bucket
|
43
49
|
end
|
data/lib/aws/s3/s3_object.rb
CHANGED
@@ -615,6 +615,13 @@ module AWS
|
|
615
615
|
# part upload is handled. Otherwise, {#write} is much simpler
|
616
616
|
# to use.
|
617
617
|
#
|
618
|
+
# Note: After you initiate multipart upload and upload one or
|
619
|
+
# more parts, you must either complete or abort multipart
|
620
|
+
# upload in order to stop getting charged for storage of the
|
621
|
+
# uploaded parts. Only after you either complete or abort
|
622
|
+
# multipart upload, Amazon S3 frees up the parts storage and
|
623
|
+
# stops charging you for the parts storage.
|
624
|
+
#
|
618
625
|
# @example Uploading an object in two parts
|
619
626
|
#
|
620
627
|
# bucket.objects.myobject.multipart_upload do |upload|
|
data/lib/aws/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.32.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:
|
11
|
+
date: 2014-01-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: uuidtools
|
@@ -235,7 +235,6 @@ files:
|
|
235
235
|
- lib/aws/ec2/client.rb
|
236
236
|
- lib/aws/ec2/collection.rb
|
237
237
|
- lib/aws/ec2/config.rb
|
238
|
-
- lib/aws/ec2/config_transform.rb
|
239
238
|
- lib/aws/ec2/customer_gateway.rb
|
240
239
|
- lib/aws/ec2/customer_gateway_collection.rb
|
241
240
|
- lib/aws/ec2/dhcp_options.rb
|
@@ -1,63 +0,0 @@
|
|
1
|
-
# Copyright 2011-2013 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
2
|
-
|
3
|
-
module AWS
|
4
|
-
class EC2
|
5
|
-
|
6
|
-
# @api private
|
7
|
-
class ConfigTransform
|
8
|
-
|
9
|
-
class << self
|
10
|
-
|
11
|
-
def transform(api_config)
|
12
|
-
["RunInstances",
|
13
|
-
"DetachVolume",
|
14
|
-
"AttachVolume",
|
15
|
-
"CreateSnapshot",
|
16
|
-
"CreateVolume",
|
17
|
-
"DescribeImageAttribute",
|
18
|
-
"DescribeInstanceAttribute"].each do |(op, wrapper)|
|
19
|
-
if op_config = api_config[:operations][op]
|
20
|
-
op_config[:output] = op_config[:output].first.values.first
|
21
|
-
end
|
22
|
-
end
|
23
|
-
|
24
|
-
api_config[:operations].each do |op, op_config|
|
25
|
-
op_config[:input] =
|
26
|
-
capitalize_input_structure(op_config[:input])
|
27
|
-
end
|
28
|
-
|
29
|
-
api_config
|
30
|
-
end
|
31
|
-
|
32
|
-
private
|
33
|
-
def capitalize_input_structure(struct)
|
34
|
-
struct.inject({}) do |m, (name, desc)|
|
35
|
-
|
36
|
-
name = name[0,1].upcase + name[1..-1]
|
37
|
-
m[name] = capitalize_input_descriptors(desc)
|
38
|
-
m
|
39
|
-
end
|
40
|
-
end
|
41
|
-
|
42
|
-
private
|
43
|
-
def capitalize_input_descriptors(desc)
|
44
|
-
desc.map do |d|
|
45
|
-
case
|
46
|
-
when d.kind_of?(Hash) && d.key?(:structure)
|
47
|
-
d.merge(:structure =>
|
48
|
-
capitalize_input_structure(d[:structure]))
|
49
|
-
when d.kind_of?(Hash) && d.key?(:list)
|
50
|
-
d.merge(:list =>
|
51
|
-
capitalize_input_descriptors(d[:list]))
|
52
|
-
else
|
53
|
-
d
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|
57
|
-
|
58
|
-
end
|
59
|
-
|
60
|
-
end
|
61
|
-
|
62
|
-
end
|
63
|
-
end
|