aws-sdk-dynamodb 1.45.0 → 1.49.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: e7ab1b7eb6c5743bf574f6f54f95c9efdf042da4
4
- data.tar.gz: 0e101caf9a248990e4ddfa52c3ca8b073847ff9d
2
+ SHA256:
3
+ metadata.gz: bd7c6a96780238aedddd187fdbd83b35bd5d31be31fd908b6c99a4aa0396500c
4
+ data.tar.gz: 5139dac4794cfd73c32552406b4050602ac2b9f39caefcb5c0a22aa6ca64f3d3
5
5
  SHA512:
6
- metadata.gz: bbcfaf39a1e03666bde252e223f55f831c99c713f9b2ea3d201e3097a1e9c84f77e1e6f20df3e86c463d6731fff669881aa278f2f54988a8d2e6d5393c43682a
7
- data.tar.gz: a384bbc0749ed6381e6893c3392b4ab6eb79726a992c8b85e46ce7ea232385d960cddd59641df1c2178b8b7c270cb76da4def58d5464f333f97ce42ffb2b0301
6
+ metadata.gz: 741f83b8c822286aa7054fd5e7a9908261fc3d42ab655617fbed64d0011eae903aac19486968ff850cb6e322dc0e3858ec5c71c960adde0cb5803f8133eba392
7
+ data.tar.gz: 7060e6d963ee0f9d2ae02801a8ee3204827c727ba8393d446e49c105b751bd01ed7cefa3bb39b248975696e74ef654b50bba023e0f44e58e268a2c6de963ea85
@@ -47,6 +47,6 @@ require_relative 'aws-sdk-dynamodb/customizations'
47
47
  # @service
48
48
  module Aws::DynamoDB
49
49
 
50
- GEM_VERSION = '1.45.0'
50
+ GEM_VERSION = '1.49.1'
51
51
 
52
52
  end
@@ -48,8 +48,8 @@ module Aws
48
48
  when true, false then { bool: obj }
49
49
  when nil then { null: true }
50
50
  else
51
- msg = "unsupported type, expected Hash, Array, Set, String, Numeric, "
52
- msg << "IO, true, false, or nil, got #{obj.class.name}"
51
+ msg = 'unsupported type, expected Hash, Array, Set, String, Numeric, '\
52
+ "IO, true, false, or nil, got #{obj.class.name}"
53
53
  raise ArgumentError, msg
54
54
  end
55
55
  end
@@ -57,14 +57,14 @@ module Aws
57
57
  private
58
58
 
59
59
  def format_set(set)
60
- return { es: [] } if set.empty?
60
+ return { ss: [] } if set.empty?
61
61
  case set.first
62
62
  when String, Symbol then { ss: set.map(&:to_s) }
63
63
  when STRINGY_TEST then { ss: set.map(&:to_str) }
64
64
  when Numeric then { ns: set.map(&:to_s) }
65
65
  when StringIO, IO then { bs: set.to_a }
66
66
  else
67
- msg = "set types only support String, Numeric, or IO objects"
67
+ msg = 'set types only support String, Numeric, or IO objects'
68
68
  raise ArgumentError, msg
69
69
  end
70
70
  end
@@ -89,7 +89,6 @@ module Aws
89
89
  when :ss then Set.new(value)
90
90
  when :ns then Set.new(value.map { |n| BigDecimal(n) })
91
91
  when :bs then Set.new(value.map { |b| StringIO.new(b) })
92
- when :es then Set.new
93
92
  else
94
93
  raise ArgumentError, "unhandled type #{type.inspect}"
95
94
  end
@@ -24,6 +24,7 @@ require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
24
24
  require 'aws-sdk-core/plugins/client_metrics_plugin.rb'
25
25
  require 'aws-sdk-core/plugins/client_metrics_send_plugin.rb'
26
26
  require 'aws-sdk-core/plugins/transfer_encoding.rb'
27
+ require 'aws-sdk-core/plugins/http_checksum.rb'
27
28
  require 'aws-sdk-core/plugins/signature_v4.rb'
28
29
  require 'aws-sdk-core/plugins/protocols/json_rpc.rb'
29
30
  require 'aws-sdk-dynamodb/plugins/extended_retries.rb'
@@ -35,11 +36,11 @@ Aws::Plugins::GlobalConfiguration.add_identifier(:dynamodb)
35
36
  module Aws::DynamoDB
36
37
  # An API client for DynamoDB. To construct a client, you need to configure a `:region` and `:credentials`.
37
38
  #
38
- # client = Aws::DynamoDB::Client.new(
39
- # region: region_name,
40
- # credentials: credentials,
41
- # # ...
42
- # )
39
+ # client = Aws::DynamoDB::Client.new(
40
+ # region: region_name,
41
+ # credentials: credentials,
42
+ # # ...
43
+ # )
43
44
  #
44
45
  # For details on configuring region and credentials see
45
46
  # the [developer guide](/sdk-for-ruby/v3/developer-guide/setup-config.html).
@@ -72,6 +73,7 @@ module Aws::DynamoDB
72
73
  add_plugin(Aws::Plugins::ClientMetricsPlugin)
73
74
  add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
74
75
  add_plugin(Aws::Plugins::TransferEncoding)
76
+ add_plugin(Aws::Plugins::HttpChecksum)
75
77
  add_plugin(Aws::Plugins::SignatureV4)
76
78
  add_plugin(Aws::Plugins::Protocols::JsonRpc)
77
79
  add_plugin(Aws::DynamoDB::Plugins::ExtendedRetries)
@@ -111,7 +113,7 @@ module Aws::DynamoDB
111
113
  # @option options [required, String] :region
112
114
  # The AWS region to connect to. The configured `:region` is
113
115
  # used to determine the service `:endpoint`. When not passed,
114
- # a default `:region` is search for in the following locations:
116
+ # a default `:region` is searched for in the following locations:
115
117
  #
116
118
  # * `Aws.config[:region]`
117
119
  # * `ENV['AWS_REGION']`
@@ -173,7 +175,7 @@ module Aws::DynamoDB
173
175
  # @option options [String] :endpoint
174
176
  # The client endpoint is normally constructed from the `:region`
175
177
  # option. You should only configure an `:endpoint` when connecting
176
- # to test endpoints. This should be avalid HTTP(S) URI.
178
+ # to test or custom endpoints. This should be a valid HTTP(S) URI.
177
179
  #
178
180
  # @option options [Integer] :endpoint_cache_max_entries (1000)
179
181
  # Used for the maximum size limit of the LRU cache storing endpoints data
@@ -188,7 +190,7 @@ module Aws::DynamoDB
188
190
  # requests fetching endpoints information. Defaults to 60 sec.
189
191
  #
190
192
  # @option options [Boolean] :endpoint_discovery (false)
191
- # When set to `true`, endpoint discovery will be enabled for operations when available. Defaults to `false`.
193
+ # When set to `true`, endpoint discovery will be enabled for operations when available.
192
194
  #
193
195
  # @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
194
196
  # The log formatter.
@@ -240,15 +242,19 @@ module Aws::DynamoDB
240
242
  #
241
243
  # @option options [String] :retry_mode ("legacy")
242
244
  # Specifies which retry algorithm to use. Values are:
243
- # * `legacy` - The pre-existing retry behavior. This is default value if
244
- # no retry mode is provided.
245
- # * `standard` - A standardized set of retry rules across the AWS SDKs.
246
- # This includes support for retry quotas, which limit the number of
247
- # unsuccessful retries a client can make.
248
- # * `adaptive` - An experimental retry mode that includes all the
249
- # functionality of `standard` mode along with automatic client side
250
- # throttling. This is a provisional mode that may change behavior
251
- # in the future.
245
+ #
246
+ # * `legacy` - The pre-existing retry behavior. This is default value if
247
+ # no retry mode is provided.
248
+ #
249
+ # * `standard` - A standardized set of retry rules across the AWS SDKs.
250
+ # This includes support for retry quotas, which limit the number of
251
+ # unsuccessful retries a client can make.
252
+ #
253
+ # * `adaptive` - An experimental retry mode that includes all the
254
+ # functionality of `standard` mode along with automatic client side
255
+ # throttling. This is a provisional mode that may change behavior
256
+ # in the future.
257
+ #
252
258
  #
253
259
  # @option options [String] :secret_access_key
254
260
  #
@@ -294,8 +300,7 @@ module Aws::DynamoDB
294
300
  #
295
301
  # @option options [Integer] :http_read_timeout (60) The default
296
302
  # number of seconds to wait for response data. This value can
297
- # safely be set
298
- # per-request on the session yielded by {#session_for}.
303
+ # safely be set per-request on the session.
299
304
  #
300
305
  # @option options [Float] :http_idle_timeout (5) The number of
301
306
  # seconds a connection is allowed to sit idle before it is
@@ -307,7 +312,7 @@ module Aws::DynamoDB
307
312
  # request body. This option has no effect unless the request has
308
313
  # "Expect" header set to "100-continue". Defaults to `nil` which
309
314
  # disables this behaviour. This value can safely be set per
310
- # request on the session yielded by {#session_for}.
315
+ # request on the session.
311
316
  #
312
317
  # @option options [Boolean] :http_wire_trace (false) When `true`,
313
318
  # HTTP debug output will be sent to the `:logger`.
@@ -507,6 +512,8 @@ module Aws::DynamoDB
507
512
  # * {Types::BatchGetItemOutput#unprocessed_keys #unprocessed_keys} => Hash&lt;String,Types::KeysAndAttributes&gt;
508
513
  # * {Types::BatchGetItemOutput#consumed_capacity #consumed_capacity} => Array&lt;Types::ConsumedCapacity&gt;
509
514
  #
515
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
516
+ #
510
517
  #
511
518
  # @example Example: To retrieve multiple items from a table
512
519
  #
@@ -939,7 +946,8 @@ module Aws::DynamoDB
939
946
  # a replication relationship between two or more DynamoDB tables with
940
947
  # the same table name in the provided Regions.
941
948
  #
942
- # <note markdown="1"> This method only applies to [Version 2017.11.29][1] of global tables.
949
+ # <note markdown="1"> This operation only applies to [Version 2017.11.29][1] of global
950
+ # tables.
943
951
  #
944
952
  # </note>
945
953
  #
@@ -964,6 +972,14 @@ module Aws::DynamoDB
964
972
  # * The global secondary indexes must have the same hash key and sort
965
973
  # key (if present).
966
974
  #
975
+ # If local secondary indexes are specified, then the following
976
+ # conditions must also be met:
977
+ #
978
+ # * The local secondary indexes must have the same name.
979
+ #
980
+ # * The local secondary indexes must have the same hash key and sort key
981
+ # (if present).
982
+ #
967
983
  # Write capacity settings should be set consistently across your replica
968
984
  # tables and secondary indexes. DynamoDB strongly recommends enabling
969
985
  # auto scaling to manage the write capacity settings for all of your
@@ -2158,13 +2174,17 @@ module Aws::DynamoDB
2158
2174
 
2159
2175
  # Returns information about the specified global table.
2160
2176
  #
2161
- # <note markdown="1"> This method only applies to [Version 2017.11.29][1] of global tables.
2177
+ # <note markdown="1"> This operation only applies to [Version 2017.11.29][1] of global
2178
+ # tables. If you are using global tables [Version 2019.11.21][2] you can
2179
+ # use [DescribeTable][3] instead.
2162
2180
  #
2163
2181
  # </note>
2164
2182
  #
2165
2183
  #
2166
2184
  #
2167
2185
  # [1]: https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/globaltables.V1.html
2186
+ # [2]: https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/globaltables.V2.html
2187
+ # [3]: https://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_DescribeTable.html
2168
2188
  #
2169
2189
  # @option params [required, String] :global_table_name
2170
2190
  # The name of the global table.
@@ -2207,7 +2227,8 @@ module Aws::DynamoDB
2207
2227
 
2208
2228
  # Describes Region-specific settings for a global table.
2209
2229
  #
2210
- # <note markdown="1"> This method only applies to [Version 2017.11.29][1] of global tables.
2230
+ # <note markdown="1"> This operation only applies to [Version 2017.11.29][1] of global
2231
+ # tables.
2211
2232
  #
2212
2233
  # </note>
2213
2234
  #
@@ -2552,6 +2573,12 @@ module Aws::DynamoDB
2552
2573
  # resp.table.archival_summary.archival_reason #=> String
2553
2574
  # resp.table.archival_summary.archival_backup_arn #=> String
2554
2575
  #
2576
+ #
2577
+ # The following waiters are defined for this operation (see {Client#wait_until} for detailed usage):
2578
+ #
2579
+ # * table_exists
2580
+ # * table_not_exists
2581
+ #
2555
2582
  # @see http://docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/DescribeTable AWS API Documentation
2556
2583
  #
2557
2584
  # @overload describe_table(params = {})
@@ -2564,7 +2591,8 @@ module Aws::DynamoDB
2564
2591
  # Describes auto scaling settings across replicas of the global table at
2565
2592
  # once.
2566
2593
  #
2567
- # <note markdown="1"> This method only applies to [Version 2019.11.21][1] of global tables.
2594
+ # <note markdown="1"> This operation only applies to [Version 2019.11.21][1] of global
2595
+ # tables.
2568
2596
  #
2569
2597
  # </note>
2570
2598
  #
@@ -2971,6 +2999,8 @@ module Aws::DynamoDB
2971
2999
  # * {Types::ListContributorInsightsOutput#contributor_insights_summaries #contributor_insights_summaries} => Array&lt;Types::ContributorInsightsSummary&gt;
2972
3000
  # * {Types::ListContributorInsightsOutput#next_token #next_token} => String
2973
3001
  #
3002
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
3003
+ #
2974
3004
  # @example Request syntax with placeholder values
2975
3005
  #
2976
3006
  # resp = client.list_contributor_insights({
@@ -2998,7 +3028,8 @@ module Aws::DynamoDB
2998
3028
 
2999
3029
  # Lists all global tables that have a replica in the specified Region.
3000
3030
  #
3001
- # <note markdown="1"> This method only applies to [Version 2017.11.29][1] of global tables.
3031
+ # <note markdown="1"> This operation only applies to [Version 2017.11.29][1] of global
3032
+ # tables.
3002
3033
  #
3003
3034
  # </note>
3004
3035
  #
@@ -3070,6 +3101,8 @@ module Aws::DynamoDB
3070
3101
  # * {Types::ListTablesOutput#table_names #table_names} => Array&lt;String&gt;
3071
3102
  # * {Types::ListTablesOutput#last_evaluated_table_name #last_evaluated_table_name} => String
3072
3103
  #
3104
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
3105
+ #
3073
3106
  #
3074
3107
  # @example Example: To list tables
3075
3108
  #
@@ -3190,9 +3223,14 @@ module Aws::DynamoDB
3190
3223
  # * [ PutItem in the AWS SDK for Ruby V2][9]
3191
3224
  #
3192
3225
  # When you add an item, the primary key attributes are the only required
3193
- # attributes. Attribute values cannot be null. String and Binary type
3194
- # attributes must have lengths greater than zero. Set type attributes
3195
- # cannot be empty. Requests with empty values will be rejected with a
3226
+ # attributes. Attribute values cannot be null.
3227
+ #
3228
+ # Empty String and Binary attribute values are allowed. Attribute values
3229
+ # of type String and Binary must have a length greater than zero if the
3230
+ # attribute is used as a key attribute for a table or index. Set type
3231
+ # attributes cannot be empty.
3232
+ #
3233
+ # Invalid Requests with empty values will be rejected with a
3196
3234
  # `ValidationException` exception.
3197
3235
  #
3198
3236
  # <note markdown="1"> To prevent a new item from replacing an existing item, use a
@@ -3237,6 +3275,10 @@ module Aws::DynamoDB
3237
3275
  # data types for those attributes must match those of the schema in the
3238
3276
  # table's attribute definition.
3239
3277
  #
3278
+ # Empty String and Binary attribute values are allowed. Attribute values
3279
+ # of type String and Binary must have a length greater than zero if the
3280
+ # attribute is used as a key attribute for a table or index.
3281
+ #
3240
3282
  # For more information about primary keys, see [Primary Key][1] in the
3241
3283
  # *Amazon DynamoDB Developer Guide*.
3242
3284
  #
@@ -3926,6 +3968,8 @@ module Aws::DynamoDB
3926
3968
  # * {Types::QueryOutput#last_evaluated_key #last_evaluated_key} => Hash&lt;String,Types::AttributeValue&gt;
3927
3969
  # * {Types::QueryOutput#consumed_capacity #consumed_capacity} => Types::ConsumedCapacity
3928
3970
  #
3971
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
3972
+ #
3929
3973
  #
3930
3974
  # @example Example: To query an item
3931
3975
  #
@@ -4773,6 +4817,8 @@ module Aws::DynamoDB
4773
4817
  # * {Types::ScanOutput#last_evaluated_key #last_evaluated_key} => Hash&lt;String,Types::AttributeValue&gt;
4774
4818
  # * {Types::ScanOutput#consumed_capacity #consumed_capacity} => Types::ConsumedCapacity
4775
4819
  #
4820
+ # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
4821
+ #
4776
4822
  #
4777
4823
  # @example Example: To scan a table
4778
4824
  #
@@ -6358,7 +6404,8 @@ module Aws::DynamoDB
6358
6404
 
6359
6405
  # Updates auto scaling settings on your global tables at once.
6360
6406
  #
6361
- # <note markdown="1"> This method only applies to [Version 2019.11.21][1] of global tables.
6407
+ # <note markdown="1"> This operation only applies to [Version 2019.11.21][1] of global
6408
+ # tables.
6362
6409
  #
6363
6410
  # </note>
6364
6411
  #
@@ -6611,7 +6658,7 @@ module Aws::DynamoDB
6611
6658
  params: params,
6612
6659
  config: config)
6613
6660
  context[:gem_name] = 'aws-sdk-dynamodb'
6614
- context[:gem_version] = '1.45.0'
6661
+ context[:gem_version] = '1.49.1'
6615
6662
  Seahorse::Client::Request.new(handlers, context)
6616
6663
  end
6617
6664
 
@@ -6677,10 +6724,10 @@ module Aws::DynamoDB
6677
6724
  # The following table lists the valid waiter names, the operations they call,
6678
6725
  # and the default `:delay` and `:max_attempts` values.
6679
6726
  #
6680
- # | waiter_name | params | :delay | :max_attempts |
6681
- # | ---------------- | ----------------- | -------- | ------------- |
6682
- # | table_exists | {#describe_table} | 20 | 25 |
6683
- # | table_not_exists | {#describe_table} | 20 | 25 |
6727
+ # | waiter_name | params | :delay | :max_attempts |
6728
+ # | ---------------- | ----------------------- | -------- | ------------- |
6729
+ # | table_exists | {Client#describe_table} | 20 | 25 |
6730
+ # | table_not_exists | {Client#describe_table} | 20 | 25 |
6684
6731
  #
6685
6732
  # @raise [Errors::FailureStateError] Raised when the waiter terminates
6686
6733
  # because the waiter has entered a state that it will not transition
@@ -6,13 +6,18 @@
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
8
  module Aws::DynamoDB
9
+
9
10
  # This class provides a resource oriented interface for DynamoDB.
10
11
  # To create a resource object:
12
+ #
11
13
  # resource = Aws::DynamoDB::Resource.new(region: 'us-west-2')
14
+ #
12
15
  # You can supply a client object with custom configuration that will be used for all resource operations.
13
- # If you do not pass +:client+, a default client will be constructed.
16
+ # If you do not pass `:client`, a default client will be constructed.
17
+ #
14
18
  # client = Aws::DynamoDB::Client.new(region: 'us-west-2')
15
19
  # resource = Aws::DynamoDB::Resource.new(client: client)
20
+ #
16
21
  class Resource
17
22
 
18
23
  # @param options ({})
@@ -394,7 +394,8 @@ module Aws::DynamoDB
394
394
  # Waiter polls an API operation until a resource enters a desired
395
395
  # state.
396
396
  #
397
- # @note The waiting operation is performed on a copy. The original resource remains unchanged
397
+ # @note The waiting operation is performed on a copy. The original resource
398
+ # remains unchanged.
398
399
  #
399
400
  # ## Basic Usage
400
401
  #
@@ -407,13 +408,15 @@ module Aws::DynamoDB
407
408
  #
408
409
  # ## Example
409
410
  #
410
- # instance.wait_until(max_attempts:10, delay:5) {|instance| instance.state.name == 'running' }
411
+ # instance.wait_until(max_attempts:10, delay:5) do |instance|
412
+ # instance.state.name == 'running'
413
+ # end
411
414
  #
412
415
  # ## Configuration
413
416
  #
414
417
  # You can configure the maximum number of polling attempts, and the
415
- # delay (in seconds) between each polling attempt. The waiting condition is set
416
- # by passing a block to {#wait_until}:
418
+ # delay (in seconds) between each polling attempt. The waiting condition is
419
+ # set by passing a block to {#wait_until}:
417
420
  #
418
421
  # # poll for ~25 seconds
419
422
  # resource.wait_until(max_attempts:5,delay:5) {|resource|...}
@@ -444,17 +447,16 @@ module Aws::DynamoDB
444
447
  # # resource did not enter the desired state in time
445
448
  # end
446
449
  #
450
+ # @yieldparam [Resource] resource to be used in the waiting condition.
447
451
  #
448
- # @yield param [Resource] resource to be used in the waiting condition
449
- #
450
- # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter terminates
451
- # because the waiter has entered a state that it will not transition
452
- # out of, preventing success.
452
+ # @raise [Aws::Waiters::Errors::FailureStateError] Raised when the waiter
453
+ # terminates because the waiter has entered a state that it will not
454
+ # transition out of, preventing success.
453
455
  #
454
456
  # yet successful.
455
457
  #
456
- # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is encountered
457
- # while polling for a resource that is not expected.
458
+ # @raise [Aws::Waiters::Errors::UnexpectedError] Raised when an error is
459
+ # encountered while polling for a resource that is not expected.
458
460
  #
459
461
  # @raise [NotImplementedError] Raised when the resource does not
460
462
  #
@@ -853,6 +855,10 @@ module Aws::DynamoDB
853
855
  # data types for those attributes must match those of the schema in the
854
856
  # table's attribute definition.
855
857
  #
858
+ # Empty String and Binary attribute values are allowed. Attribute values
859
+ # of type String and Binary must have a length greater than zero if the
860
+ # attribute is used as a key attribute for a table or index.
861
+ #
856
862
  # For more information about primary keys, see [Primary Key][1] in the
857
863
  # *Amazon DynamoDB Developer Guide*.
858
864
  #
@@ -5163,6 +5163,11 @@ module Aws::DynamoDB
5163
5163
  # the data types for those attributes must match those of the schema
5164
5164
  # in the table's attribute definition.
5165
5165
  #
5166
+ # Empty String and Binary attribute values are allowed. Attribute
5167
+ # values of type String and Binary must have a length greater than
5168
+ # zero if the attribute is used as a key attribute for a table or
5169
+ # index.
5170
+ #
5166
5171
  # For more information about primary keys, see [Primary Key][1] in the
5167
5172
  # *Amazon DynamoDB Developer Guide*.
5168
5173
  #
@@ -8,6 +8,68 @@
8
8
  require 'aws-sdk-core/waiters'
9
9
 
10
10
  module Aws::DynamoDB
11
+ # Waiters are utility methods that poll for a particular state to occur
12
+ # on a client. Waiters can fail after a number of attempts at a polling
13
+ # interval defined for the service client.
14
+ #
15
+ # For a list of operations that can be waited for and the
16
+ # client methods called for each operation, see the table below or the
17
+ # {Client#wait_until} field documentation for the {Client}.
18
+ #
19
+ # # Invoking a Waiter
20
+ # To invoke a waiter, call #wait_until on a {Client}. The first parameter
21
+ # is the waiter name, which is specific to the service client and indicates
22
+ # which operation is being waited for. The second parameter is a hash of
23
+ # parameters that are passed to the client method called by the waiter,
24
+ # which varies according to the waiter name.
25
+ #
26
+ # # Wait Failures
27
+ # To catch errors in a waiter, use WaiterFailed,
28
+ # as shown in the following example.
29
+ #
30
+ # rescue rescue Aws::Waiters::Errors::WaiterFailed => error
31
+ # puts "failed waiting for instance running: #{error.message}
32
+ # end
33
+ #
34
+ # # Configuring a Waiter
35
+ # Each waiter has a default polling interval and a maximum number of
36
+ # attempts it will make before returning control to your program.
37
+ # To set these values, use the `max_attempts` and `delay` parameters
38
+ # in your `#wait_until` call.
39
+ # The following example waits for up to 25 seconds, polling every five seconds.
40
+ #
41
+ # client.wait_until(...) do |w|
42
+ # w.max_attempts = 5
43
+ # w.delay = 5
44
+ # end
45
+ #
46
+ # To disable wait failures, set the value of either of these parameters
47
+ # to `nil`.
48
+ #
49
+ # # Extending a Waiter
50
+ # To modify the behavior of waiters, you can register callbacks that are
51
+ # triggered before each polling attempt and before waiting.
52
+ #
53
+ # The following example implements an exponential backoff in a waiter
54
+ # by doubling the amount of time to wait on every attempt.
55
+ #
56
+ # client.wait_until(...) do |w|
57
+ # w.interval = 0 # disable normal sleep
58
+ # w.before_wait do |n, resp|
59
+ # sleep(n ** 2)
60
+ # end
61
+ # end
62
+ #
63
+ # # Available Waiters
64
+ #
65
+ # The following table lists the valid waiter names, the operations they call,
66
+ # and the default `:delay` and `:max_attempts` values.
67
+ #
68
+ # | waiter_name | params | :delay | :max_attempts |
69
+ # | ---------------- | ----------------------- | -------- | ------------- |
70
+ # | table_exists | {Client#describe_table} | 20 | 25 |
71
+ # | table_not_exists | {Client#describe_table} | 20 | 25 |
72
+ #
11
73
  module Waiters
12
74
 
13
75
  class TableExists
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-dynamodb
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.45.0
4
+ version: 1.49.1
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: 2020-03-09 00:00:00.000000000 Z
11
+ date: 2020-06-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '3'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 3.71.0
22
+ version: 3.99.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: '3'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 3.71.0
32
+ version: 3.99.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -88,7 +88,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
88
88
  version: '0'
89
89
  requirements: []
90
90
  rubyforge_project:
91
- rubygems_version: 2.5.2.3
91
+ rubygems_version: 2.7.6.2
92
92
  signing_key:
93
93
  specification_version: 4
94
94
  summary: AWS SDK for Ruby - DynamoDB