aws-sdk 1.12.0 → 1.13.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.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -2
  3. data/bin/aws-rb +18 -0
  4. data/lib/aws/api_config/{CloudFront-2012-07-01.yml → CloudFront-2013-05-12.yml} +73 -23
  5. data/lib/aws/api_config/{RDS-2013-02-12.yml → RDS-2013-05-15.yml} +92 -5
  6. data/lib/aws/api_config/Redshift-2012-12-01.yml +188 -12
  7. data/lib/aws/api_config/STS-2011-06-15.yml +10 -0
  8. data/lib/aws/auto_scaling/client.rb +6 -0
  9. data/lib/aws/cloud_formation/client.rb +6 -0
  10. data/lib/aws/cloud_front/client.rb +37 -1
  11. data/lib/aws/cloud_search/client.rb +6 -0
  12. data/lib/aws/cloud_watch/client.rb +6 -0
  13. data/lib/aws/core.rb +15 -20
  14. data/lib/aws/core/client.rb +36 -0
  15. data/lib/aws/core/credential_providers.rb +45 -0
  16. data/lib/aws/core/region_collection.rb +4 -1
  17. data/lib/aws/data_pipeline/client.rb +6 -0
  18. data/lib/aws/direct_connect/client.rb +6 -0
  19. data/lib/aws/dynamo_db/client.rb +35 -1249
  20. data/lib/aws/dynamo_db/client/v20111205.rb +1266 -0
  21. data/lib/aws/dynamo_db/client/v20120810.rb +1409 -0
  22. data/lib/aws/dynamo_db/client_base.rb +1 -0
  23. data/lib/aws/dynamo_db/client_v2.rb +25 -1396
  24. data/lib/aws/ec2/client.rb +6 -0
  25. data/lib/aws/elastic_beanstalk/client.rb +6 -0
  26. data/lib/aws/elastic_transcoder/client.rb +6 -0
  27. data/lib/aws/elasticache/client.rb +6 -0
  28. data/lib/aws/elb/client.rb +6 -0
  29. data/lib/aws/emr/client.rb +6 -0
  30. data/lib/aws/glacier/client.rb +14 -8
  31. data/lib/aws/iam/client.rb +6 -0
  32. data/lib/aws/import_export/client.rb +6 -0
  33. data/lib/aws/ops_works/client.rb +6 -0
  34. data/lib/aws/rds/client.rb +83 -18
  35. data/lib/aws/record/abstract_base.rb +19 -22
  36. data/lib/aws/record/attributes.rb +5 -1
  37. data/lib/aws/record/hash_model.rb +50 -6
  38. data/lib/aws/record/model.rb +26 -0
  39. data/lib/aws/record/validator.rb +1 -1
  40. data/lib/aws/redshift/client.rb +186 -53
  41. data/lib/aws/route_53/client.rb +6 -0
  42. data/lib/aws/route_53/hosted_zone.rb +1 -1
  43. data/lib/aws/route_53/resource_record_set.rb +3 -3
  44. data/lib/aws/s3/client.rb +4 -1
  45. data/lib/aws/s3/presigned_post.rb +18 -21
  46. data/lib/aws/simple_db/client.rb +6 -0
  47. data/lib/aws/simple_email_service/client.rb +6 -0
  48. data/lib/aws/simple_email_service/identity.rb +1 -1
  49. data/lib/aws/simple_workflow/client.rb +24 -18
  50. data/lib/aws/sns/client.rb +6 -0
  51. data/lib/aws/sqs/client.rb +21 -15
  52. data/lib/aws/storage_gateway/client.rb +6 -0
  53. data/lib/aws/sts/client.rb +57 -38
  54. data/lib/aws/support/client.rb +6 -0
  55. data/lib/aws/version.rb +1 -1
  56. metadata +6 -4
@@ -17,6 +17,7 @@ module AWS
17
17
  class DynamoDB
18
18
 
19
19
  # Client class for Amazon DynamoDB.
20
+ # @api private
20
21
  class ClientBase < Core::JSONClient
21
22
 
22
23
  # @private
@@ -14,1402 +14,31 @@
14
14
  module AWS
15
15
  class DynamoDB
16
16
 
17
- # Client class for Amazon DynamoDB.
18
- class ClientV2 < ClientBase
19
-
20
- # client methods #
21
-
22
- # @!method batch_get_item(options = {})
23
- # Calls the BatchGetItem API operation.
24
- # @param [Hash] options
25
- #
26
- # * `:request_items` - *required* - (Hash<String,Hash>) A map of one or
27
- # more table names and, for each table, the corresponding primary
28
- # keys for the items to retrieve. Each table name can be invoked only
29
- # once. Each element in the map consists of the following: Keys - An
30
- # array of primary key attribute values that define specific items in
31
- # the table. AttributesToGet - One or more attributes to be retrieved
32
- # from the table or index. By default, all attributes are returned.
33
- # If a specified attribute is not found, it does not appear in the
34
- # result. ConsistentRead - If `true` , a strongly consistent read is
35
- # used; if `false` (the default), an eventually consistent read is
36
- # used.
37
- # * `:keys` - *required* - (Array<Hash<String,Hash>>) Represents the
38
- # primary key attribute values that define the items and the
39
- # attributes associated with the items.
40
- # * `:s` - (String) Represents a String data type
41
- # * `:n` - (String) Represents a Number data type
42
- # * `:b` - (String) Represents a Binary data type
43
- # * `:ss` - (Array<String>) Represents a String set data type
44
- # * `:ns` - (Array<String>) Represents a Number set data type
45
- # * `:bs` - (Array<String>) Represents a Binary set data type
46
- # * `:attributes_to_get` - (Array<String>) Represents one or more
47
- # attributes to retrieve from the table or index. If no attribute
48
- # names are specified then all attributes will be returned. If any
49
- # of the specified attributes are not found, they will not appear
50
- # in the result.
51
- # * `:consistent_read` - (Boolean) Represents the consistency of a
52
- # read operation. If set to `true` , then a strongly consistent
53
- # read is used; otherwise, an eventually consistent read is used.
54
- # * `:return_consumed_capacity` - (String) Valid values include:
55
- # * `TOTAL`
56
- # * `NONE`
57
- # @return [Core::Response]
58
- # The #data method of the response object returns
59
- # a hash with the following structure:
60
- #
61
- # * `:responses` - (Hash<String,Hash>)
62
- # * `:member` - (Hash<String,Hash>)
63
- # * `:s` - (String)
64
- # * `:n` - (String)
65
- # * `:b` - (String)
66
- # * `:ss` - (Array<String>)
67
- # * `:ns` - (Array<String>)
68
- # * `:bs` - (Array<Blob>)
69
- # * `:unprocessed_keys` - (Hash<String,Hash>)
70
- # * `:member` - (Hash<String,Hash>)
71
- # * `:s` - (String)
72
- # * `:n` - (String)
73
- # * `:b` - (String)
74
- # * `:ss` - (Array<String>)
75
- # * `:ns` - (Array<String>)
76
- # * `:bs` - (Array<Blob>)
77
- # * `:attributes_to_get` - (Array<String>)
78
- # * `:consistent_read` - (Boolean)
79
- # * `:consumed_capacity` - (Array<Hash>)
80
- # * `:table_name` - (String)
81
- # * `:capacity_units` - (Numeric)
82
-
83
- # @!method batch_write_item(options = {})
84
- # Calls the BatchWriteItem API operation.
85
- # @param [Hash] options
86
- #
87
- # * `:request_items` - *required* - (Hash<String,Array<Hash>>) A map of
88
- # one or more table names and, for each table, a list of operations
89
- # to be performed (DeleteRequest or PutRequest). Each element in the
90
- # map consists of the following: DeleteRequest - Perform a DeleteItem
91
- # operation on the specified item. The item to be deleted is
92
- # identified by a Key subelement: Key - A map of primary key
93
- # attribute values that uniquely identify the item. Each entry in
94
- # this map consists of an attribute name and an attribute value.
95
- # PutRequest - Perform a PutItem operation on the specified item. The
96
- # item to be put is identified by an Item subelement: Item - A map of
97
- # attributes and their values. Each entry in this map consists of an
98
- # attribute name and an attribute value. Attribute values must not be
99
- # null; string and binary type attributes must have lengths greater
100
- # than zero; and set type attributes must not be empty. Requests that
101
- # contain empty values will be rejected with a ValidationException.
102
- # If you specify any attributes that are part of an index key, then
103
- # the data types for those attributes must match those of the schema
104
- # in the table's attribute definition.
105
- # * `:put_request` - (Hash) Represents a request to perform a
106
- # DeleteItem operation.
107
- # * `:item` - *required* - (Hash<String,Hash>) A map of attribute
108
- # name to attribute values, representing the primary key of an
109
- # item to be processed by PutItem. All of the table's primary key
110
- # attributes must be specified, and their data types must match
111
- # those of the table's key schema. If any attributes are present
112
- # in the item which are part of an index key schema for the
113
- # table, their types must match the index key schema.
114
- # * `:s` - (String) Represents a String data type
115
- # * `:n` - (String) Represents a Number data type
116
- # * `:b` - (String) Represents a Binary data type
117
- # * `:ss` - (Array<String>) Represents a String set data type
118
- # * `:ns` - (Array<String>) Represents a Number set data type
119
- # * `:bs` - (Array<String>) Represents a Binary set data type
120
- # * `:delete_request` - (Hash) Represents a request to perform a
121
- # PutItem operation.
122
- # * `:key` - *required* - (Hash<String,Hash>) A map of attribute
123
- # name to attribute values, representing the primary key of the
124
- # item to delete. All of the table's primary key attributes must
125
- # be specified, and their data types must match those of the
126
- # table's key schema.
127
- # * `:s` - (String) Represents a String data type
128
- # * `:n` - (String) Represents a Number data type
129
- # * `:b` - (String) Represents a Binary data type
130
- # * `:ss` - (Array<String>) Represents a String set data type
131
- # * `:ns` - (Array<String>) Represents a Number set data type
132
- # * `:bs` - (Array<String>) Represents a Binary set data type
133
- # * `:return_consumed_capacity` - (String) Valid values include:
134
- # * `TOTAL`
135
- # * `NONE`
136
- # * `:return_item_collection_metrics` - (String) Valid values include:
137
- # * `SIZE`
138
- # * `NONE`
139
- # @return [Core::Response]
140
- # The #data method of the response object returns
141
- # a hash with the following structure:
142
- #
143
- # * `:unprocessed_items` - (Hash<String,Hash>)
144
- # * `:value` - (Array<Hash>)
145
- # * `:put_request` - (Hash)
146
- # * `:item` - (Hash<String,Hash>)
147
- # * `:s` - (String)
148
- # * `:n` - (String)
149
- # * `:b` - (String)
150
- # * `:ss` - (Array<String>)
151
- # * `:ns` - (Array<String>)
152
- # * `:bs` - (Array<Blob>)
153
- # * `:delete_request` - (Hash)
154
- # * `:key` - (Hash<String,Hash>)
155
- # * `:s` - (String)
156
- # * `:n` - (String)
157
- # * `:b` - (String)
158
- # * `:ss` - (Array<String>)
159
- # * `:ns` - (Array<String>)
160
- # * `:bs` - (Array<Blob>)
161
- # * `:item_collection_metrics` - (Hash<String,Hash>)
162
- # * `:value` - (Array<Hash>)
163
- # * `:item_collection_key` - (Hash<String,Hash>)
164
- # * `:s` - (String)
165
- # * `:n` - (String)
166
- # * `:b` - (String)
167
- # * `:ss` - (Array<String>)
168
- # * `:ns` - (Array<String>)
169
- # * `:bs` - (Array<Blob>)
170
- # * `:size_estimate_range_gb` - (Array<Float>)
171
- # * `:consumed_capacity` - (Array<Hash>)
172
- # * `:table_name` - (String)
173
- # * `:capacity_units` - (Numeric)
174
-
175
- # @!method create_table(options = {})
176
- # Calls the CreateTable API operation.
177
- # @param [Hash] options
178
- #
179
- # * `:attribute_definitions` - *required* - (Array<Hash>) An array of
180
- # attributes that describe the key schema for the table and indexes.
181
- # * `:attribute_name` - *required* - (String) A name for the
182
- # attribute.
183
- # * `:attribute_type` - *required* - (String) The data type for the
184
- # attribute. Valid values include:
185
- # * `S`
186
- # * `N`
187
- # * `B`
188
- # * `:table_name` - *required* - (String) The name of the table to
189
- # create.
190
- # * `:key_schema` - *required* - (Array<Hash>) Specifies the attributes
191
- # that make up the primary key for the table. The attributes in
192
- # KeySchema must also be defined in the AttributeDefinitions array.
193
- # For more information, see Data Model . Each KeySchemaElement in the
194
- # array is composed of: AttributeName - The name of this key
195
- # attribute. KeyType - Determines whether the key attribute is HASH
196
- # or RANGE. For a primary key that consists of a hash attribute, you
197
- # must specify exactly one element with a KeyType of HASH. For a
198
- # primary key that consists of hash and range attributes, you must
199
- # specify exactly two elements, in this order: The first element must
200
- # have a KeyType of HASH, and the second element must have a KeyType
201
- # of RANGE. For more information, see Specifying the Primary Key .
202
- # * `:attribute_name` - *required* - (String) Represents the name of
203
- # a key attribute.
204
- # * `:key_type` - *required* - (String) Represents the attribute
205
- # data, consisting of the data type and the attribute value itself.
206
- # Valid values include:
207
- # * `HASH`
208
- # * `RANGE`
209
- # * `:local_secondary_indexes` - (Array<Hash>) One or more secondary
210
- # indexes (the maximum is five) to be created on the table. Each
211
- # index is scoped to a given hash key value. There is a 10 gigabyte
212
- # size limit per hash key; otherwise, the size of a local secondary
213
- # index is unconstrained. Each secondary index in the array includes
214
- # the following: IndexName - The name of the secondary index. Must be
215
- # unique only for this table. KeySchema - Specifies the key schema
216
- # for the index. The key schema must begin with the same hash key
217
- # attribute as the table.
218
- # * `:index_name` - *required* - (String) Represents the name of the
219
- # secondary index. The name must be unique among all other indexes
220
- # on this table.
221
- # * `:key_schema` - *required* - (Array<Hash>) Represents the
222
- # complete index key schema, which consists of one or more pairs of
223
- # attribute names and key types (HASH or RANGE).
224
- # * `:attribute_name` - *required* - (String) Represents the name
225
- # of a key attribute.
226
- # * `:key_type` - *required* - (String) Represents the attribute
227
- # data, consisting of the data type and the attribute value
228
- # itself. Valid values include:
229
- # * `HASH`
230
- # * `RANGE`
231
- # * `:projection` - *required* - (Hash)
232
- # * `:projection_type` - (String) Represents the set of attributes
233
- # that are projected into the index: KEYS_ONLY - Only the index
234
- # and primary keys are projected into the index. INCLUDE - Only
235
- # the specified table attributes are projected into the index.
236
- # The list of projected attributes are in NonKeyAttributes. ALL -
237
- # All of the table attributes are projected into the index. Valid
238
- # values include:
239
- # * `ALL`
240
- # * `KEYS_ONLY`
241
- # * `INCLUDE`
242
- # * `:non_key_attributes` - (Array<String>) Represents the non-key
243
- # attribute names which will be projected into the index. The
244
- # total count of attributes specified in NonKeyAttributes, summed
245
- # across all of the local secondary indexes, must not exceed 20.
246
- # If you project the same attribute into two different indexes,
247
- # this counts as two distinct attributes when determining the
248
- # total.
249
- # * `:provisioned_throughput` - *required* - (Hash)
250
- # * `:read_capacity_units` - *required* - (Integer) The maximum
251
- # number of strongly consistent reads consumed per second before
252
- # returns a ThrottlingException. For more information, see
253
- # Specifying Read and Write Requirements .
254
- # * `:write_capacity_units` - *required* - (Integer) The maximum
255
- # number of writes consumed per second before returns a
256
- # ThrottlingException. For more information, see Specifying Read
257
- # and Write Requirements .
258
- # @return [Core::Response]
259
- # The #data method of the response object returns
260
- # a hash with the following structure:
261
- #
262
- # * `:table_description` - (Hash)
263
- # * `:attribute_definitions` - (Array<Hash>)
264
- # * `:attribute_name` - (String)
265
- # * `:attribute_type` - (String)
266
- # * `:table_name` - (String)
267
- # * `:key_schema` - (Array<Hash>)
268
- # * `:attribute_name` - (String)
269
- # * `:key_type` - (String)
270
- # * `:table_status` - (String)
271
- # * `:creation_date_time` - (Time)
272
- # * `:provisioned_throughput` - (Hash)
273
- # * `:last_increase_date_time` - (Time)
274
- # * `:last_decrease_date_time` - (Time)
275
- # * `:number_of_decreases_today` - (Integer)
276
- # * `:read_capacity_units` - (Integer)
277
- # * `:write_capacity_units` - (Integer)
278
- # * `:table_size_bytes` - (Integer)
279
- # * `:item_count` - (Integer)
280
- # * `:local_secondary_indexes` - (Array<Hash>)
281
- # * `:index_name` - (String)
282
- # * `:key_schema` - (Array<Hash>)
283
- # * `:attribute_name` - (String)
284
- # * `:key_type` - (String)
285
- # * `:projection` - (Hash)
286
- # * `:projection_type` - (String)
287
- # * `:non_key_attributes` - (Array<String>)
288
- # * `:index_size_bytes` - (Integer)
289
- # * `:item_count` - (Integer)
290
-
291
- # @!method delete_item(options = {})
292
- # Calls the DeleteItem API operation.
293
- # @param [Hash] options
294
- #
295
- # * `:table_name` - *required* - (String) The name of the table from
296
- # which to delete the item.
297
- # * `:key` - *required* - (Hash<String,Hash>) A map of attribute names
298
- # to AttributeValue objects, representing the primary key of the item
299
- # to delete.
300
- # * `:s` - (String) Represents a String data type
301
- # * `:n` - (String) Represents a Number data type
302
- # * `:b` - (String) Represents a Binary data type
303
- # * `:ss` - (Array<String>) Represents a String set data type
304
- # * `:ns` - (Array<String>) Represents a Number set data type
305
- # * `:bs` - (Array<String>) Represents a Binary set data type
306
- # * `:expected` - (Hash<String,Hash>) A map of attribute/condition
307
- # pairs. This is the conditional block for the DeleteItemoperation.
308
- # All the conditions must be met for the operation to succeed.
309
- # * `:value` - (Hash) Specify whether or not a value already exists
310
- # and has a specific content for the attribute name-value pair.
311
- # * `:s` - (String) Represents a String data type
312
- # * `:n` - (String) Represents a Number data type
313
- # * `:b` - (String) Represents a Binary data type
314
- # * `:ss` - (Array<String>) Represents a String set data type
315
- # * `:ns` - (Array<String>) Represents a Number set data type
316
- # * `:bs` - (Array<String>) Represents a Binary set data type
317
- # * `:exists` - (Boolean) Causes to evaluate the value before
318
- # attempting a conditional operation: If Exists is `true` , will
319
- # check to see if that attribute value already exists in the table.
320
- # If it is found, then the operation succeeds. If it is not found,
321
- # the operation fails with a ConditionalCheckFailedException. If
322
- # Exists is `false` , assumes that the attribute value does not
323
- # exist in the table. If in fact the value does not exist, then the
324
- # assumption is valid and the operation succeeds. If the value is
325
- # found, despite the assumption that it does not exist, the
326
- # operation fails with a ConditionalCheckFailedException. The
327
- # default setting for Exists is `true` . If you supply a Value all
328
- # by itself, assumes the attribute exists: You don't have to set
329
- # Exists to `true` , because it is implied. returns a
330
- # ValidationException if: Exists is `true` but there is no Value to
331
- # check. (You expect a value to exist, but don't specify what that
332
- # value is.) Exists is `false` but you also specify a Value. (You
333
- # cannot expect an attribute to have a value, while also expecting
334
- # it not to exist.) If you specify more than one condition for
335
- # Exists, then all of the conditions must evaluate to `true` . (In
336
- # other words, the conditions are ANDed together.) Otherwise, the
337
- # conditional operation will fail.
338
- # * `:return_values` - (String) Use ReturnValues if you want to get the
339
- # item attributes as they appeared before they were deleted. For
340
- # DeleteItem, the valid values are: NONE - If ReturnValues is not
341
- # specified, or if its value is NONE, then nothing is returned. (This
342
- # is the default for ReturnValues.) ALL_OLD - The content of the old
343
- # item is returned. Valid values include:
344
- # * `NONE`
345
- # * `ALL_OLD`
346
- # * `UPDATED_OLD`
347
- # * `ALL_NEW`
348
- # * `UPDATED_NEW`
349
- # * `:return_consumed_capacity` - (String) Valid values include:
350
- # * `TOTAL`
351
- # * `NONE`
352
- # * `:return_item_collection_metrics` - (String) Valid values include:
353
- # * `SIZE`
354
- # * `NONE`
355
- # @return [Core::Response]
356
- # The #data method of the response object returns
357
- # a hash with the following structure:
358
- #
359
- # * `:attributes` - (Hash<String,Hash>)
360
- # * `:s` - (String)
361
- # * `:n` - (String)
362
- # * `:b` - (String)
363
- # * `:ss` - (Array<String>)
364
- # * `:ns` - (Array<String>)
365
- # * `:bs` - (Array<Blob>)
366
- # * `:consumed_capacity` - (Hash)
367
- # * `:table_name` - (String)
368
- # * `:capacity_units` - (Numeric)
369
- # * `:item_collection_metrics` - (Hash)
370
- # * `:item_collection_key` - (Hash<String,Hash>)
371
- # * `:s` - (String)
372
- # * `:n` - (String)
373
- # * `:b` - (String)
374
- # * `:ss` - (Array<String>)
375
- # * `:ns` - (Array<String>)
376
- # * `:bs` - (Array<Blob>)
377
- # * `:size_estimate_range_gb` - (Array<Float>)
378
-
379
- # @!method delete_table(options = {})
380
- # Calls the DeleteTable API operation.
381
- # @param [Hash] options
382
- #
383
- # * `:table_name` - *required* - (String) The name of the table to
384
- # delete.
385
- # @return [Core::Response]
386
- # The #data method of the response object returns
387
- # a hash with the following structure:
388
- #
389
- # * `:table_description` - (Hash)
390
- # * `:attribute_definitions` - (Array<Hash>)
391
- # * `:attribute_name` - (String)
392
- # * `:attribute_type` - (String)
393
- # * `:table_name` - (String)
394
- # * `:key_schema` - (Array<Hash>)
395
- # * `:attribute_name` - (String)
396
- # * `:key_type` - (String)
397
- # * `:table_status` - (String)
398
- # * `:creation_date_time` - (Time)
399
- # * `:provisioned_throughput` - (Hash)
400
- # * `:last_increase_date_time` - (Time)
401
- # * `:last_decrease_date_time` - (Time)
402
- # * `:number_of_decreases_today` - (Integer)
403
- # * `:read_capacity_units` - (Integer)
404
- # * `:write_capacity_units` - (Integer)
405
- # * `:table_size_bytes` - (Integer)
406
- # * `:item_count` - (Integer)
407
- # * `:local_secondary_indexes` - (Array<Hash>)
408
- # * `:index_name` - (String)
409
- # * `:key_schema` - (Array<Hash>)
410
- # * `:attribute_name` - (String)
411
- # * `:key_type` - (String)
412
- # * `:projection` - (Hash)
413
- # * `:projection_type` - (String)
414
- # * `:non_key_attributes` - (Array<String>)
415
- # * `:index_size_bytes` - (Integer)
416
- # * `:item_count` - (Integer)
417
-
418
- # @!method describe_table(options = {})
419
- # Calls the DescribeTable API operation.
420
- # @param [Hash] options
421
- #
422
- # * `:table_name` - *required* - (String) The name of the table to
423
- # describe.
424
- # @return [Core::Response]
425
- # The #data method of the response object returns
426
- # a hash with the following structure:
427
- #
428
- # * `:table` - (Hash)
429
- # * `:attribute_definitions` - (Array<Hash>)
430
- # * `:attribute_name` - (String)
431
- # * `:attribute_type` - (String)
432
- # * `:table_name` - (String)
433
- # * `:key_schema` - (Array<Hash>)
434
- # * `:attribute_name` - (String)
435
- # * `:key_type` - (String)
436
- # * `:table_status` - (String)
437
- # * `:creation_date_time` - (Time)
438
- # * `:provisioned_throughput` - (Hash)
439
- # * `:last_increase_date_time` - (Time)
440
- # * `:last_decrease_date_time` - (Time)
441
- # * `:number_of_decreases_today` - (Integer)
442
- # * `:read_capacity_units` - (Integer)
443
- # * `:write_capacity_units` - (Integer)
444
- # * `:table_size_bytes` - (Integer)
445
- # * `:item_count` - (Integer)
446
- # * `:local_secondary_indexes` - (Array<Hash>)
447
- # * `:index_name` - (String)
448
- # * `:key_schema` - (Array<Hash>)
449
- # * `:attribute_name` - (String)
450
- # * `:key_type` - (String)
451
- # * `:projection` - (Hash)
452
- # * `:projection_type` - (String)
453
- # * `:non_key_attributes` - (Array<String>)
454
- # * `:index_size_bytes` - (Integer)
455
- # * `:item_count` - (Integer)
456
-
457
- # @!method get_item(options = {})
458
- # Calls the GetItem API operation.
459
- # @param [Hash] options
460
- #
461
- # * `:table_name` - *required* - (String) The name of the table
462
- # containing the requested item.
463
- # * `:key` - *required* - (Hash<String,Hash>) A map of attribute names
464
- # to AttributeValue objects, representing the primary key of the item
465
- # to retrieve.
466
- # * `:s` - (String) Represents a String data type
467
- # * `:n` - (String) Represents a Number data type
468
- # * `:b` - (String) Represents a Binary data type
469
- # * `:ss` - (Array<String>) Represents a String set data type
470
- # * `:ns` - (Array<String>) Represents a Number set data type
471
- # * `:bs` - (Array<String>) Represents a Binary set data type
472
- # * `:attributes_to_get` - (Array<String>)
473
- # * `:consistent_read` - (Boolean)
474
- # * `:return_consumed_capacity` - (String) Valid values include:
475
- # * `TOTAL`
476
- # * `NONE`
477
- # @return [Core::Response]
478
- # The #data method of the response object returns
479
- # a hash with the following structure:
480
- #
481
- # * `:item` - (Hash<String,Hash>)
482
- # * `:s` - (String)
483
- # * `:n` - (String)
484
- # * `:b` - (String)
485
- # * `:ss` - (Array<String>)
486
- # * `:ns` - (Array<String>)
487
- # * `:bs` - (Array<Blob>)
488
- # * `:consumed_capacity` - (Hash)
489
- # * `:table_name` - (String)
490
- # * `:capacity_units` - (Numeric)
491
-
492
- # @!method list_tables(options = {})
493
- # Calls the ListTables API operation.
494
- # @param [Hash] options
495
- #
496
- # * `:exclusive_start_table_name` - (String) The name of the table that
497
- # starts the list. If you already ran a ListTables operation and
498
- # received a LastEvaluatedTableName value in the response, use that
499
- # value here to continue the list.
500
- # * `:limit` - (Integer) A maximum number of table names to return.
501
- # @return [Core::Response]
502
- # The #data method of the response object returns
503
- # a hash with the following structure:
504
- #
505
- # * `:table_names` - (Array<String>)
506
- # * `:last_evaluated_table_name` - (String)
507
-
508
- # @!method put_item(options = {})
509
- # Calls the PutItem API operation.
510
- # @param [Hash] options
511
- #
512
- # * `:table_name` - *required* - (String) The name of the table to
513
- # contain the item.
514
- # * `:item` - *required* - (Hash<String,Hash>) A map of attribute
515
- # name/value pairs, one for each attribute. Only the primary key
516
- # attributes are required; you can optionally provide other attribute
517
- # name-value pairs for the item. If you specify any attributes that
518
- # are part of an index key, then the data types for those attributes
519
- # must match those of the schema in the table's attribute definition.
520
- # For more information about primary keys, see Primary Key . Each
521
- # element in the Item map is an AttributeValue object.
522
- # * `:s` - (String) Represents a String data type
523
- # * `:n` - (String) Represents a Number data type
524
- # * `:b` - (String) Represents a Binary data type
525
- # * `:ss` - (Array<String>) Represents a String set data type
526
- # * `:ns` - (Array<String>) Represents a Number set data type
527
- # * `:bs` - (Array<String>) Represents a Binary set data type
528
- # * `:expected` - (Hash<String,Hash>) A map of attribute/condition
529
- # pairs. This is the conditional block for the PutItem operation. All
530
- # the conditions must be met for the operation to succeed.
531
- # * `:value` - (Hash) Specify whether or not a value already exists
532
- # and has a specific content for the attribute name-value pair.
533
- # * `:s` - (String) Represents a String data type
534
- # * `:n` - (String) Represents a Number data type
535
- # * `:b` - (String) Represents a Binary data type
536
- # * `:ss` - (Array<String>) Represents a String set data type
537
- # * `:ns` - (Array<String>) Represents a Number set data type
538
- # * `:bs` - (Array<String>) Represents a Binary set data type
539
- # * `:exists` - (Boolean) Causes to evaluate the value before
540
- # attempting a conditional operation: If Exists is `true` , will
541
- # check to see if that attribute value already exists in the table.
542
- # If it is found, then the operation succeeds. If it is not found,
543
- # the operation fails with a ConditionalCheckFailedException. If
544
- # Exists is `false` , assumes that the attribute value does not
545
- # exist in the table. If in fact the value does not exist, then the
546
- # assumption is valid and the operation succeeds. If the value is
547
- # found, despite the assumption that it does not exist, the
548
- # operation fails with a ConditionalCheckFailedException. The
549
- # default setting for Exists is `true` . If you supply a Value all
550
- # by itself, assumes the attribute exists: You don't have to set
551
- # Exists to `true` , because it is implied. returns a
552
- # ValidationException if: Exists is `true` but there is no Value to
553
- # check. (You expect a value to exist, but don't specify what that
554
- # value is.) Exists is `false` but you also specify a Value. (You
555
- # cannot expect an attribute to have a value, while also expecting
556
- # it not to exist.) If you specify more than one condition for
557
- # Exists, then all of the conditions must evaluate to `true` . (In
558
- # other words, the conditions are ANDed together.) Otherwise, the
559
- # conditional operation will fail.
560
- # * `:return_values` - (String) Use ReturnValues if you want to get the
561
- # item attributes as they appeared before they were updated with the
562
- # PutItem request. For PutItem, the valid values are: NONE - If
563
- # ReturnValues is not specified, or if its value is NONE, then
564
- # nothing is returned. (This is the default for ReturnValues.)
565
- # ALL_OLD - If PutItem overwrote an attribute name-value pair, then
566
- # the content of the old item is returned. Valid values include:
567
- # * `NONE`
568
- # * `ALL_OLD`
569
- # * `UPDATED_OLD`
570
- # * `ALL_NEW`
571
- # * `UPDATED_NEW`
572
- # * `:return_consumed_capacity` - (String) Valid values include:
573
- # * `TOTAL`
574
- # * `NONE`
575
- # * `:return_item_collection_metrics` - (String) Valid values include:
576
- # * `SIZE`
577
- # * `NONE`
578
- # @return [Core::Response]
579
- # The #data method of the response object returns
580
- # a hash with the following structure:
581
- #
582
- # * `:attributes` - (Hash<String,Hash>)
583
- # * `:s` - (String)
584
- # * `:n` - (String)
585
- # * `:b` - (String)
586
- # * `:ss` - (Array<String>)
587
- # * `:ns` - (Array<String>)
588
- # * `:bs` - (Array<Blob>)
589
- # * `:consumed_capacity` - (Hash)
590
- # * `:table_name` - (String)
591
- # * `:capacity_units` - (Numeric)
592
- # * `:item_collection_metrics` - (Hash)
593
- # * `:item_collection_key` - (Hash<String,Hash>)
594
- # * `:s` - (String)
595
- # * `:n` - (String)
596
- # * `:b` - (String)
597
- # * `:ss` - (Array<String>)
598
- # * `:ns` - (Array<String>)
599
- # * `:bs` - (Array<Blob>)
600
- # * `:size_estimate_range_gb` - (Array<Float>)
601
-
602
- # @!method query(options = {})
603
- # Calls the Query API operation.
604
- # @param [Hash] options
605
- #
606
- # * `:table_name` - *required* - (String) The name of the table
607
- # containing the requested items.
608
- # * `:index_name` - (String) The name of an index on the table to
609
- # query.
610
- # * `:select` - (String) The attributes to be returned in the result.
611
- # You can retrieve all item attributes, specific item attributes, the
612
- # count of matching items, or in the case of an index, some or all of
613
- # the attributes projected into the index. ALL_ATTRIBUTES: Returns
614
- # all of the item attributes. For a table, this is the default. For
615
- # an index, this mode causes to fetch the full item from the table
616
- # for each matching item in the index. If the index is configured to
617
- # project all item attributes, the matching items will not be fetched
618
- # from the table. Fetching items from the table incurs additional
619
- # throughput cost and latency. ALL_PROJECTED_ATTRIBUTES: Allowed only
620
- # when querying an index. Retrieves all attributes which have been
621
- # projected into the index. If the index is configured to project all
622
- # attributes, this is equivalent to specifying ALL_ATTRIBUTES. COUNT:
623
- # Returns the number of matching items, rather than the matching
624
- # items themselves. SPECIFIC_ATTRIBUTES : Returns only the attributes
625
- # listed in AttributesToGet. This is equivalent to specifying
626
- # AttributesToGet without specifying any value for Select. When
627
- # neither Select nor AttributesToGet are specified, defaults to
628
- # ALL_ATTRIBUTES when accessing a table, and ALL_PROJECTED_ATTRIBUTES
629
- # when accessing an index. You cannot use both Select and
630
- # AttributesToGet together in a single request, unless the value for
631
- # Select is SPECIFIC_ATTRIBUTES. (This usage is equivalent to
632
- # specifying AttributesToGet without any value for Select.) Valid
633
- # values include:
634
- # * `ALL_ATTRIBUTES`
635
- # * `ALL_PROJECTED_ATTRIBUTES`
636
- # * `SPECIFIC_ATTRIBUTES`
637
- # * `COUNT`
638
- # * `:attributes_to_get` - (Array<String>) You cannot use both
639
- # AttributesToGet and Select together in a Query request, unless the
640
- # value for Select is SPECIFIC_ATTRIBUTES. (This usage is equivalent
641
- # to specifying AttributesToGet without any value for Select.)
642
- # * `:limit` - (Integer)
643
- # * `:consistent_read` - (Boolean)
644
- # * `:key_conditions` - (Hash<String,Hash>) The selection criteria for
645
- # the query. For a query on a table, you can only have conditions on
646
- # the table primary key attributes. you must specify the hash key
647
- # attribute name and value as an EQ condition. You can optionally
648
- # specify a second condition, referring to the range key attribute.
649
- # For a query on a secondary index, you can only have conditions on
650
- # the index key attributes. You must specify the index hash attribute
651
- # name and value as an EQ condition. You can optionally specify a
652
- # second condition, referring to the index key range attribute.
653
- # Multiple conditions are evaluated using "AND"; in other words, all
654
- # of the conditions must be met in order for an item to appear in the
655
- # results results. Each KeyConditions element consists of an
656
- # attribute name to compare, along with the following:
657
- # AttributeValueList - One or more values to evaluate against the
658
- # supplied attribute. This list contains exactly one value, except
659
- # for a BETWEEN or IN comparison, in which case the list contains two
660
- # values. For type Number, value comparisons are numeric. String
661
- # value comparisons for greater than, equals, or less than are based
662
- # on ASCII character code values. For example, a is greater than A,
663
- # and aa is greater than B. For a list of code values, see
664
- # http://en.wikipedia.org/wiki/ASCII#ASCII_printable_characters. For
665
- # Binary, treats each byte of the binary data as unsigned when it
666
- # compares binary values, for example when evaluating query
667
- # expressions. ComparisonOperator - A comparator for evaluating
668
- # attributes. For example, equals, greater than, less than, etc. For
669
- # information on specifying data types in JSON, see JSON Data Format
670
- # . The following are descriptions of each comparison operator. EQ :
671
- # Equal. AttributeValueList can contain only one AttributeValue of
672
- # type String, Number, or Binary (not a set). If an item contains an
673
- # AttributeValue of a different type than the one specified in the
674
- # request, the value does not match. For example, {"S":"6"} does not
675
- # equal {"N":"6"}. Also, {"N":"6"} does not equal {"NS":["6", "2",
676
- # "1"]}. LE : Less than or equal. AttributeValueList can contain only
677
- # one AttributeValue of type String, Number, or Binary (not a set).
678
- # If an item contains an AttributeValue of a different type than the
679
- # one specified in the request, the value does not match. For
680
- # example, {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does
681
- # not compare to {"NS":["6", "2", "1"]}. LT : Less than.
682
- # AttributeValueList can contain only one AttributeValue of type
683
- # String, Number, or Binary (not a set). If an item contains an
684
- # AttributeValue of a different type than the one specified in the
685
- # request, the value does not match. For example, {"S":"6"} does not
686
- # equal {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6",
687
- # "2", "1"]}. GE : Greater than or equal. AttributeValueList can
688
- # contain only one AttributeValue of type String, Number, or Binary
689
- # (not a set). If an item contains an AttributeValue of a different
690
- # type than the one specified in the request, the value does not
691
- # match. For example, {"S":"6"} does not equal {"N":"6"}. Also,
692
- # {"N":"6"} does not compare to {"NS":["6", "2", "1"]}. GT : Greater
693
- # than. AttributeValueList can contain only one AttributeValue of
694
- # type String, Number, or Binary (not a set). If an item contains an
695
- # AttributeValue of a different type than the one specified in the
696
- # request, the value does not match. For example, {"S":"6"} does not
697
- # equal {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6",
698
- # "2", "1"]}. BEGINS_WITH : checks for a prefix. AttributeValueList
699
- # can contain only one AttributeValue of type String or Binary (not a
700
- # Number or a set). The target attribute of the comparison must be a
701
- # String or Binary (not a Number or a set). BETWEEN : Greater than or
702
- # equal to the first value, and less than or equal to the second
703
- # value. AttributeValueList must contain two AttributeValue elements
704
- # of the same type, either String, Number, or Binary (not a set). A
705
- # target attribute matches if the target value is greater than, or
706
- # equal to, the first element and less than, or equal to, the second
707
- # element. If an item contains an AttributeValue of a different type
708
- # than the one specified in the request, the value does not match.
709
- # For example, {"S":"6"} does not compare to {"N":"6"}. Also,
710
- # {"N":"6"} does not compare to {"NS":["6", "2", "1"]}
711
- # * `:attribute_value_list` - (Array<Hash>) Represents one or more
712
- # values to evaluate against the supplied attribute. This list
713
- # contains exactly one value, except for a BETWEEN or IN
714
- # comparison, in which case the list contains two values. For type
715
- # Number, value comparisons are numeric. String value comparisons
716
- # for greater than, equals, or less than are based on ASCII
717
- # character code values. For example, a is greater than A, and aa
718
- # is greater than B. For a list of code values, see
719
- # http://en.wikipedia.org/wiki/ASCII#ASCII_printable_characters.
720
- # For Binary, treats each byte of the binary data as unsigned when
721
- # it compares binary values, for example when evaluating query
722
- # expressions.
723
- # * `:s` - (String) Represents a String data type
724
- # * `:n` - (String) Represents a Number data type
725
- # * `:b` - (String) Represents a Binary data type
726
- # * `:ss` - (Array<String>) Represents a String set data type
727
- # * `:ns` - (Array<String>) Represents a Number set data type
728
- # * `:bs` - (Array<String>) Represents a Binary set data type
729
- # * `:comparison_operator` - *required* - (String) Represents a
730
- # comparator for evaluating attributes. For example, equals,
731
- # greater than, less than, etc. For information on specifying data
732
- # types in JSON, see JSON Data Format . The following are
733
- # descriptions of each comparison operator. EQ : Equal.
734
- # AttributeValueList can contain only one AttributeValue of type
735
- # String, Number, or Binary (not a set). If an item contains an
736
- # AttributeValue of a different type than the one specified in the
737
- # request, the value does not match. For example, {"S":"6"} does
738
- # not equal {"N":"6"}. Also, {"N":"6"} does not equal {"NS":["6",
739
- # "2", "1"]}. NE : Not equal. AttributeValueList can contain only
740
- # one AttributeValue of type String, Number, or Binary (not a set).
741
- # If an item contains an AttributeValue of a different type than
742
- # the one specified in the request, the value does not match. For
743
- # example, {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does
744
- # not equal {"NS":["6", "2", "1"]}. LE : Less than or equal.
745
- # AttributeValueList can contain only one AttributeValue of type
746
- # String, Number, or Binary (not a set). If an item contains an
747
- # AttributeValue of a different type than the one specified in the
748
- # request, the value does not match. For example, {"S":"6"} does
749
- # not equal {"N":"6"}. Also, {"N":"6"} does not compare to
750
- # {"NS":["6", "2", "1"]}. LT : Less than. AttributeValueList can
751
- # contain only one AttributeValue of type String, Number, or Binary
752
- # (not a set). If an item contains an AttributeValue of a different
753
- # type than the one specified in the request, the value does not
754
- # match. For example, {"S":"6"} does not equal {"N":"6"}. Also,
755
- # {"N":"6"} does not compare to {"NS":["6", "2", "1"]}. GE :
756
- # Greater than or equal. AttributeValueList can contain only one
757
- # AttributeValue of type String, Number, or Binary (not a set). If
758
- # an item contains an AttributeValue of a different type than the
759
- # one specified in the request, the value does not match. For
760
- # example, {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does
761
- # not compare to {"NS":["6", "2", "1"]}. GT : Greater than.
762
- # AttributeValueList can contain only one AttributeValue of type
763
- # String, Number, or Binary (not a set). If an item contains an
764
- # AttributeValue of a different type than the one specified in the
765
- # request, the value does not match. For example, {"S":"6"} does
766
- # not equal {"N":"6"}. Also, {"N":"6"} does not compare to
767
- # {"NS":["6", "2", "1"]}. NOT_NULL : The attribute exists. NULL :
768
- # The attribute does not exist. CONTAINS : checks for a
769
- # subsequence, or value in a set. AttributeValueList can contain
770
- # only one AttributeValue of type String, Number, or Binary (not a
771
- # set). If the target attribute of the comparison is a String, then
772
- # the operation checks for a substring match. If the target
773
- # attribute of the comparison is Binary, then the operation looks
774
- # for a subsequence of the target that matches the input. If the
775
- # target attribute of the comparison is a set ("SS", "NS", or
776
- # "BS"), then the operation checks for a member of the set (not as
777
- # a substring). NOT_CONTAINS : checks for absence of a subsequence,
778
- # or absence of a value in a set. AttributeValueList can contain
779
- # only one AttributeValue of type String, Number, or Binary (not a
780
- # set). If the target attribute of the comparison is a String, then
781
- # the operation checks for the absence of a substring match. If the
782
- # target attribute of the comparison is Binary, then the operation
783
- # checks for the absence of a subsequence of the target that
784
- # matches the input. If the target attribute of the comparison is a
785
- # set ("SS", "NS", or "BS"), then the operation checks for the
786
- # absence of a member of the set (not as a substring). BEGINS_WITH
787
- # : checks for a prefix. AttributeValueList can contain only one
788
- # AttributeValue of type String or Binary (not a Number or a set).
789
- # The target attribute of the comparison must be a String or Binary
790
- # (not a Number or a set). IN : checks for exact matches.
791
- # AttributeValueList can contain more than one AttributeValue of
792
- # type String, Number, or Binary (not a set). The target attribute
793
- # of the comparison must be of the same type and exact value to
794
- # match. A String never matches a String set. BETWEEN : Greater
795
- # than or equal to the first value, and less than or equal to the
796
- # second value. AttributeValueList must contain two AttributeValue
797
- # elements of the same type, either String, Number, or Binary (not
798
- # a set). A target attribute matches if the target value is greater
799
- # than, or equal to, the first element and less than, or equal to,
800
- # the second element. If an item contains an AttributeValue of a
801
- # different type than the one specified in the request, the value
802
- # does not match. For example, {"S":"6"} does not compare to
803
- # {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6", "2",
804
- # "1"]} Valid values include:
805
- # * `EQ`
806
- # * `NE`
807
- # * `IN`
808
- # * `LE`
809
- # * `LT`
810
- # * `GE`
811
- # * `GT`
812
- # * `BETWEEN`
813
- # * `NOT_NULL`
814
- # * `NULL`
815
- # * `CONTAINS`
816
- # * `NOT_CONTAINS`
817
- # * `BEGINS_WITH`
818
- # * `:scan_index_forward` - (Boolean) Specifies ascending ( `true` ) or
819
- # descending ( `false` ) traversal of the index. returns results
820
- # reflecting the requested order determined by the range key. If the
821
- # data type is Number, the results are returned in numeric order. For
822
- # String, the results are returned in order of ASCII character code
823
- # values. For Binary, Amazon DynamoDB treats each byte of the binary
824
- # data as unsigned when it compares binary values. If
825
- # ScanIndexForward is not specified, the results are returned in
826
- # ascending order.
827
- # * `:exclusive_start_key` - (Hash<String,Hash>)
828
- # * `:s` - (String) Represents a String data type
829
- # * `:n` - (String) Represents a Number data type
830
- # * `:b` - (String) Represents a Binary data type
831
- # * `:ss` - (Array<String>) Represents a String set data type
832
- # * `:ns` - (Array<String>) Represents a Number set data type
833
- # * `:bs` - (Array<String>) Represents a Binary set data type
834
- # * `:return_consumed_capacity` - (String) Valid values include:
835
- # * `TOTAL`
836
- # * `NONE`
837
- # @return [Core::Response]
838
- # The #data method of the response object returns
839
- # a hash with the following structure:
840
- #
841
- # * `:member` - (Hash<String,Hash>)
842
- # * `:s` - (String)
843
- # * `:n` - (String)
844
- # * `:b` - (String)
845
- # * `:ss` - (Array<String>)
846
- # * `:ns` - (Array<String>)
847
- # * `:bs` - (Array<Blob>)
848
- # * `:count` - (Integer)
849
- # * `:last_evaluated_key` - (Hash<String,Hash>)
850
- # * `:s` - (String)
851
- # * `:n` - (String)
852
- # * `:b` - (String)
853
- # * `:ss` - (Array<String>)
854
- # * `:ns` - (Array<String>)
855
- # * `:bs` - (Array<Blob>)
856
- # * `:consumed_capacity` - (Hash)
857
- # * `:table_name` - (String)
858
- # * `:capacity_units` - (Numeric)
859
-
860
- # @!method scan(options = {})
861
- # Calls the Scan API operation.
862
- # @param [Hash] options
863
- #
864
- # * `:table_name` - *required* - (String) The name of the table
865
- # containing the requested items.
866
- # * `:attributes_to_get` - (Array<String>)
867
- # * `:limit` - (Integer)
868
- # * `:select` - (String) The attributes to be returned in the result.
869
- # You can retrieve all item attributes, specific item attributes, the
870
- # count of matching items, or in the case of an index, some or all of
871
- # the attributes projected into the index. ALL_ATTRIBUTES: Returns
872
- # all of the item attributes. For a table, this is the default. For
873
- # an index, this mode causes to fetch the full item from the table
874
- # for each matching item in the index. If the index is configured to
875
- # project all item attributes, the matching items will not be fetched
876
- # from the table. Fetching items from the table incurs additional
877
- # throughput cost and latency. ALL_PROJECTED_ATTRIBUTES: Retrieves
878
- # all attributes which have been projected into the index. If the
879
- # index is configured to project all attributes, this is equivalent
880
- # to specifying ALL_ATTRIBUTES. COUNT: Returns the number of matching
881
- # items, rather than the matching items themselves.
882
- # SPECIFIC_ATTRIBUTES : Returns only the attributes listed in
883
- # AttributesToGet. This is equivalent to specifying AttributesToGet
884
- # without specifying any value for Select. When neither Select nor
885
- # AttributesToGet are specified, defaults to ALL_ATTRIBUTES when
886
- # accessing a table, and ALL_PROJECTED_ATTRIBUTES when accessing an
887
- # index. You cannot use both Select and AttributesToGet together in a
888
- # single request, unless the value for Select is SPECIFIC_ATTRIBUTES.
889
- # (This usage is equivalent to specifying AttributesToGet without any
890
- # value for Select.) Valid values include:
891
- # * `ALL_ATTRIBUTES`
892
- # * `ALL_PROJECTED_ATTRIBUTES`
893
- # * `SPECIFIC_ATTRIBUTES`
894
- # * `COUNT`
895
- # * `:scan_filter` - (Hash<String,Hash>) Evaluates the scan results and
896
- # returns only the desired values. Multiple conditions are treated as
897
- # "AND" operations: all conditions must be met to be included in the
898
- # results. Each ScanConditions element consists of an attribute name
899
- # to compare, along with the following: AttributeValueList - One or
900
- # more values to evaluate against the supplied attribute. This list
901
- # contains exactly one value, except for a BETWEEN or IN comparison,
902
- # in which case the list contains two values. For type Number, value
903
- # comparisons are numeric. String value comparisons for greater than,
904
- # equals, or less than are based on ASCII character code values. For
905
- # example, a is greater than A, and aa is greater than B. For a list
906
- # of code values, see
907
- # http://en.wikipedia.org/wiki/ASCII#ASCII_printable_characters. For
908
- # Binary, treats each byte of the binary data as unsigned when it
909
- # compares binary values, for example when evaluating query
910
- # expressions. ComparisonOperator - A comparator for evaluating
911
- # attributes. For example, equals, greater than, less than, etc. For
912
- # information on specifying data types in JSON, see JSON Data Format
913
- # . The following are descriptions of each comparison operator. EQ :
914
- # Equal. AttributeValueList can contain only one AttributeValue of
915
- # type String, Number, or Binary (not a set). If an item contains an
916
- # AttributeValue of a different type than the one specified in the
917
- # request, the value does not match. For example, {"S":"6"} does not
918
- # equal {"N":"6"}. Also, {"N":"6"} does not equal {"NS":["6", "2",
919
- # "1"]}. NE : Not equal. AttributeValueList can contain only one
920
- # AttributeValue of type String, Number, or Binary (not a set). If an
921
- # item contains an AttributeValue of a different type than the one
922
- # specified in the request, the value does not match. For example,
923
- # {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does not equal
924
- # {"NS":["6", "2", "1"]}. LE : Less than or equal. AttributeValueList
925
- # can contain only one AttributeValue of type String, Number, or
926
- # Binary (not a set). If an item contains an AttributeValue of a
927
- # different type than the one specified in the request, the value
928
- # does not match. For example, {"S":"6"} does not equal {"N":"6"}.
929
- # Also, {"N":"6"} does not compare to {"NS":["6", "2", "1"]}. LT :
930
- # Less than. AttributeValueList can contain only one AttributeValue
931
- # of type String, Number, or Binary (not a set). If an item contains
932
- # an AttributeValue of a different type than the one specified in the
933
- # request, the value does not match. For example, {"S":"6"} does not
934
- # equal {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6",
935
- # "2", "1"]}. GE : Greater than or equal. AttributeValueList can
936
- # contain only one AttributeValue of type String, Number, or Binary
937
- # (not a set). If an item contains an AttributeValue of a different
938
- # type than the one specified in the request, the value does not
939
- # match. For example, {"S":"6"} does not equal {"N":"6"}. Also,
940
- # {"N":"6"} does not compare to {"NS":["6", "2", "1"]}. GT : Greater
941
- # than. AttributeValueList can contain only one AttributeValue of
942
- # type String, Number, or Binary (not a set). If an item contains an
943
- # AttributeValue of a different type than the one specified in the
944
- # request, the value does not match. For example, {"S":"6"} does not
945
- # equal {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6",
946
- # "2", "1"]}. NOT_NULL : The attribute exists. NULL : The attribute
947
- # does not exist. CONTAINS : checks for a subsequence, or value in a
948
- # set. AttributeValueList can contain only one AttributeValue of type
949
- # String, Number, or Binary (not a set). If the target attribute of
950
- # the comparison is a String, then the operation checks for a
951
- # substring match. If the target attribute of the comparison is
952
- # Binary, then the operation looks for a subsequence of the target
953
- # that matches the input. If the target attribute of the comparison
954
- # is a set ("SS", "NS", or "BS"), then the operation checks for a
955
- # member of the set (not as a substring). NOT_CONTAINS : checks for
956
- # absence of a subsequence, or absence of a value in a set.
957
- # AttributeValueList can contain only one AttributeValue of type
958
- # String, Number, or Binary (not a set). If the target attribute of
959
- # the comparison is a String, then the operation checks for the
960
- # absence of a substring match. If the target attribute of the
961
- # comparison is Binary, then the operation checks for the absence of
962
- # a subsequence of the target that matches the input. If the target
963
- # attribute of the comparison is a set ("SS", "NS", or "BS"), then
964
- # the operation checks for the absence of a member of the set (not as
965
- # a substring). BEGINS_WITH : checks for a prefix. AttributeValueList
966
- # can contain only one AttributeValue of type String or Binary (not a
967
- # Number or a set). The target attribute of the comparison must be a
968
- # String or Binary (not a Number or a set). IN : checks for exact
969
- # matches. AttributeValueList can contain more than one
970
- # AttributeValue of type String, Number, or Binary (not a set). The
971
- # target attribute of the comparison must be of the same type and
972
- # exact value to match. A String never matches a String set. BETWEEN
973
- # : Greater than or equal to the first value, and less than or equal
974
- # to the second value. AttributeValueList must contain two
975
- # AttributeValue elements of the same type, either String, Number, or
976
- # Binary (not a set). A target attribute matches if the target value
977
- # is greater than, or equal to, the first element and less than, or
978
- # equal to, the second element. If an item contains an AttributeValue
979
- # of a different type than the one specified in the request, the
980
- # value does not match. For example, {"S":"6"} does not compare to
981
- # {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6", "2",
982
- # "1"]}
983
- # * `:attribute_value_list` - (Array<Hash>) Represents one or more
984
- # values to evaluate against the supplied attribute. This list
985
- # contains exactly one value, except for a BETWEEN or IN
986
- # comparison, in which case the list contains two values. For type
987
- # Number, value comparisons are numeric. String value comparisons
988
- # for greater than, equals, or less than are based on ASCII
989
- # character code values. For example, a is greater than A, and aa
990
- # is greater than B. For a list of code values, see
991
- # http://en.wikipedia.org/wiki/ASCII#ASCII_printable_characters.
992
- # For Binary, treats each byte of the binary data as unsigned when
993
- # it compares binary values, for example when evaluating query
994
- # expressions.
995
- # * `:s` - (String) Represents a String data type
996
- # * `:n` - (String) Represents a Number data type
997
- # * `:b` - (String) Represents a Binary data type
998
- # * `:ss` - (Array<String>) Represents a String set data type
999
- # * `:ns` - (Array<String>) Represents a Number set data type
1000
- # * `:bs` - (Array<String>) Represents a Binary set data type
1001
- # * `:comparison_operator` - *required* - (String) Represents a
1002
- # comparator for evaluating attributes. For example, equals,
1003
- # greater than, less than, etc. For information on specifying data
1004
- # types in JSON, see JSON Data Format . The following are
1005
- # descriptions of each comparison operator. EQ : Equal.
1006
- # AttributeValueList can contain only one AttributeValue of type
1007
- # String, Number, or Binary (not a set). If an item contains an
1008
- # AttributeValue of a different type than the one specified in the
1009
- # request, the value does not match. For example, {"S":"6"} does
1010
- # not equal {"N":"6"}. Also, {"N":"6"} does not equal {"NS":["6",
1011
- # "2", "1"]}. NE : Not equal. AttributeValueList can contain only
1012
- # one AttributeValue of type String, Number, or Binary (not a set).
1013
- # If an item contains an AttributeValue of a different type than
1014
- # the one specified in the request, the value does not match. For
1015
- # example, {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does
1016
- # not equal {"NS":["6", "2", "1"]}. LE : Less than or equal.
1017
- # AttributeValueList can contain only one AttributeValue of type
1018
- # String, Number, or Binary (not a set). If an item contains an
1019
- # AttributeValue of a different type than the one specified in the
1020
- # request, the value does not match. For example, {"S":"6"} does
1021
- # not equal {"N":"6"}. Also, {"N":"6"} does not compare to
1022
- # {"NS":["6", "2", "1"]}. LT : Less than. AttributeValueList can
1023
- # contain only one AttributeValue of type String, Number, or Binary
1024
- # (not a set). If an item contains an AttributeValue of a different
1025
- # type than the one specified in the request, the value does not
1026
- # match. For example, {"S":"6"} does not equal {"N":"6"}. Also,
1027
- # {"N":"6"} does not compare to {"NS":["6", "2", "1"]}. GE :
1028
- # Greater than or equal. AttributeValueList can contain only one
1029
- # AttributeValue of type String, Number, or Binary (not a set). If
1030
- # an item contains an AttributeValue of a different type than the
1031
- # one specified in the request, the value does not match. For
1032
- # example, {"S":"6"} does not equal {"N":"6"}. Also, {"N":"6"} does
1033
- # not compare to {"NS":["6", "2", "1"]}. GT : Greater than.
1034
- # AttributeValueList can contain only one AttributeValue of type
1035
- # String, Number, or Binary (not a set). If an item contains an
1036
- # AttributeValue of a different type than the one specified in the
1037
- # request, the value does not match. For example, {"S":"6"} does
1038
- # not equal {"N":"6"}. Also, {"N":"6"} does not compare to
1039
- # {"NS":["6", "2", "1"]}. NOT_NULL : The attribute exists. NULL :
1040
- # The attribute does not exist. CONTAINS : checks for a
1041
- # subsequence, or value in a set. AttributeValueList can contain
1042
- # only one AttributeValue of type String, Number, or Binary (not a
1043
- # set). If the target attribute of the comparison is a String, then
1044
- # the operation checks for a substring match. If the target
1045
- # attribute of the comparison is Binary, then the operation looks
1046
- # for a subsequence of the target that matches the input. If the
1047
- # target attribute of the comparison is a set ("SS", "NS", or
1048
- # "BS"), then the operation checks for a member of the set (not as
1049
- # a substring). NOT_CONTAINS : checks for absence of a subsequence,
1050
- # or absence of a value in a set. AttributeValueList can contain
1051
- # only one AttributeValue of type String, Number, or Binary (not a
1052
- # set). If the target attribute of the comparison is a String, then
1053
- # the operation checks for the absence of a substring match. If the
1054
- # target attribute of the comparison is Binary, then the operation
1055
- # checks for the absence of a subsequence of the target that
1056
- # matches the input. If the target attribute of the comparison is a
1057
- # set ("SS", "NS", or "BS"), then the operation checks for the
1058
- # absence of a member of the set (not as a substring). BEGINS_WITH
1059
- # : checks for a prefix. AttributeValueList can contain only one
1060
- # AttributeValue of type String or Binary (not a Number or a set).
1061
- # The target attribute of the comparison must be a String or Binary
1062
- # (not a Number or a set). IN : checks for exact matches.
1063
- # AttributeValueList can contain more than one AttributeValue of
1064
- # type String, Number, or Binary (not a set). The target attribute
1065
- # of the comparison must be of the same type and exact value to
1066
- # match. A String never matches a String set. BETWEEN : Greater
1067
- # than or equal to the first value, and less than or equal to the
1068
- # second value. AttributeValueList must contain two AttributeValue
1069
- # elements of the same type, either String, Number, or Binary (not
1070
- # a set). A target attribute matches if the target value is greater
1071
- # than, or equal to, the first element and less than, or equal to,
1072
- # the second element. If an item contains an AttributeValue of a
1073
- # different type than the one specified in the request, the value
1074
- # does not match. For example, {"S":"6"} does not compare to
1075
- # {"N":"6"}. Also, {"N":"6"} does not compare to {"NS":["6", "2",
1076
- # "1"]} Valid values include:
1077
- # * `EQ`
1078
- # * `NE`
1079
- # * `IN`
1080
- # * `LE`
1081
- # * `LT`
1082
- # * `GE`
1083
- # * `GT`
1084
- # * `BETWEEN`
1085
- # * `NOT_NULL`
1086
- # * `NULL`
1087
- # * `CONTAINS`
1088
- # * `NOT_CONTAINS`
1089
- # * `BEGINS_WITH`
1090
- # * `:exclusive_start_key` - (Hash<String,Hash>) In a parallel scan, a
1091
- # Scan request that includes ExclusiveStartKey must specify the same
1092
- # segment whose previous Scan returned the corresponding value of
1093
- # LastEvaluatedKey.
1094
- # * `:s` - (String) Represents a String data type
1095
- # * `:n` - (String) Represents a Number data type
1096
- # * `:b` - (String) Represents a Binary data type
1097
- # * `:ss` - (Array<String>) Represents a String set data type
1098
- # * `:ns` - (Array<String>) Represents a Number set data type
1099
- # * `:bs` - (Array<String>) Represents a Binary set data type
1100
- # * `:return_consumed_capacity` - (String) Valid values include:
1101
- # * `TOTAL`
1102
- # * `NONE`
1103
- # * `:total_segments` - (Integer) For a parallel Scan request,
1104
- # TotalSegments represents the total number of segments into which
1105
- # the Scan operation will be divided. The value of TotalSegments
1106
- # corresponds to the number of application workers that will perform
1107
- # the parallel scan. For example, if you want to scan a table using
1108
- # four application threads, you would specify a TotalSegments value
1109
- # of 4. The value for TotalSegments must be greater than or equal to
1110
- # 1, and less than or equal to 4096. If you specify a TotalSegments
1111
- # value of 1, the Scan will be sequential rather than parallel. If
1112
- # you specify TotalSegments, you must also specify Segment.
1113
- # * `:segment` - (Integer) For a parallel Scan request, Segment
1114
- # identifies an individual segment to be scanned by an application
1115
- # worker. Segment IDs are zero-based, so the first segment is always
1116
- # 0. For example, if you want to scan a table using four application
1117
- # threads, the first thread would specify a Segment value of 0, the
1118
- # second thread would specify 1, and so on. The value of
1119
- # LastEvaluatedKey returned from a parallel Scan request must be used
1120
- # as ExclusiveStartKey with the same Segment ID in a subsequent Scan
1121
- # operation. The value for Segment must be greater than or equal to
1122
- # 0, and less than the value provided for TotalSegments. If you
1123
- # specify Segment, you must also specify TotalSegments.
1124
- # @return [Core::Response]
1125
- # The #data method of the response object returns
1126
- # a hash with the following structure:
1127
- #
1128
- # * `:member` - (Hash<String,Hash>)
1129
- # * `:s` - (String)
1130
- # * `:n` - (String)
1131
- # * `:b` - (String)
1132
- # * `:ss` - (Array<String>)
1133
- # * `:ns` - (Array<String>)
1134
- # * `:bs` - (Array<Blob>)
1135
- # * `:count` - (Integer)
1136
- # * `:scanned_count` - (Integer)
1137
- # * `:last_evaluated_key` - (Hash<String,Hash>)
1138
- # * `:s` - (String)
1139
- # * `:n` - (String)
1140
- # * `:b` - (String)
1141
- # * `:ss` - (Array<String>)
1142
- # * `:ns` - (Array<String>)
1143
- # * `:bs` - (Array<Blob>)
1144
- # * `:consumed_capacity` - (Hash)
1145
- # * `:table_name` - (String)
1146
- # * `:capacity_units` - (Numeric)
1147
-
1148
- # @!method update_item(options = {})
1149
- # Calls the UpdateItem API operation.
1150
- # @param [Hash] options
1151
- #
1152
- # * `:table_name` - *required* - (String) The name of the table
1153
- # containing the item to update.
1154
- # * `:key` - *required* - (Hash<String,Hash>) The primary key that
1155
- # defines the item. Each element consists of an attribute name and a
1156
- # value for that attribute.
1157
- # * `:s` - (String) Represents a String data type
1158
- # * `:n` - (String) Represents a Number data type
1159
- # * `:b` - (String) Represents a Binary data type
1160
- # * `:ss` - (Array<String>) Represents a String set data type
1161
- # * `:ns` - (Array<String>) Represents a Number set data type
1162
- # * `:bs` - (Array<String>) Represents a Binary set data type
1163
- # * `:attribute_updates` - (Hash<String,Hash>) The names of attributes
1164
- # to be modified, the action to perform on each, and the new value
1165
- # for each. If you are updating an attribute that is an index key
1166
- # attribute for any indexes on that table, the attribute type must
1167
- # match the index key type defined in the AttributesDefinition of the
1168
- # table description. You can use UpdateItem to update any non-key
1169
- # attributes. Attribute values cannot be null. String and binary type
1170
- # attributes must have lengths greater than zero. Set type attributes
1171
- # must not be empty. Requests with empty values will be rejected with
1172
- # a ValidationException. Each AttributeUpdates element consists of an
1173
- # attribute name to modify, along with the following: Value - The new
1174
- # value, if applicable, for this attribute. Action - Specifies how to
1175
- # perform the update. Valid values for Action are PUT, DELETE, and
1176
- # ADD. The behavior depends on whether the specified primary key
1177
- # already exists in the table. If an item with the specified Key is
1178
- # found in the table: PUT - Adds the specified attribute to the item.
1179
- # If the attribute already exists, it is replaced by the new value.
1180
- # DELETE - If no value is specified, the attribute and its value are
1181
- # removed from the item. The data type of the specified value must
1182
- # match the existing value's data type. If a set of values is
1183
- # specified, then those values are subtracted from the old set. For
1184
- # example, if the attribute value was the set [a,b,c] and the DELETE
1185
- # action specified [a,c], then the final attribute value would be
1186
- # [b]. Specifying an empty set is an error. ADD - If the attribute
1187
- # does not already exist, then the attribute and its values are added
1188
- # to the item. If the attribute does exist, then the behavior of ADD
1189
- # depends on the data type of the attribute: If the existing
1190
- # attribute is a number, and if Value is also a number, then the
1191
- # Value is mathematically added to the existing attribute. If Value
1192
- # is a negative number, then it is subtracted from the existing
1193
- # attribute. If you use ADD to increment or decrement a number value
1194
- # for an item that doesn't exist before the update, uses 0 as the
1195
- # initial value. In addition, if you use ADD to update an existing
1196
- # item, and intend to increment or decrement an attribute value which
1197
- # does not yet exist, uses 0 as the initial value. For example,
1198
- # suppose that the item you want to update does not yet have an
1199
- # attribute named itemcount, but you decide to ADD the number 3 to
1200
- # this attribute anyway, even though it currently does not exist.
1201
- # will create the itemcount attribute, set its initial value to 0,
1202
- # and finally add 3 to it. The result will be a new itemcount
1203
- # attribute in the item, with a value of 3. If the existing data type
1204
- # is a set, and if the Value is also a set, then the Value is added
1205
- # to the existing set. (This is a set operation, not mathematical
1206
- # addition.) For example, if the attribute value was the set [1,2],
1207
- # and the ADD action specified [3], then the final attribute value
1208
- # would be [1,2,3]. An error occurs if an Add action is specified for
1209
- # a set attribute and the attribute type specified does not match the
1210
- # existing set type. Both sets must have the same primitive data
1211
- # type. For example, if the existing data type is a set of strings,
1212
- # the Value must also be a set of strings. The same holds `true` for
1213
- # number sets and binary sets. This action is only valid for an
1214
- # existing attribute whose data type is number or is a set. Do not
1215
- # use ADD for any other data types. If no item with the specified Key
1216
- # is found: PUT - creates a new item with the specified primary key,
1217
- # and then adds the attribute. DELETE - Nothing happens; there is no
1218
- # attribute to delete. ADD - creates an item with the supplied
1219
- # primary key and number (or set of numbers) for the attribute value.
1220
- # The only data types allowed are number and number set; no other
1221
- # data types can be specified. If you specify any attributes that are
1222
- # part of an index key, then the data types for those attributes must
1223
- # match those of the schema in the table's attribute definition.
1224
- # * `:value` - (Hash)
1225
- # * `:s` - (String) Represents a String data type
1226
- # * `:n` - (String) Represents a Number data type
1227
- # * `:b` - (String) Represents a Binary data type
1228
- # * `:ss` - (Array<String>) Represents a String set data type
1229
- # * `:ns` - (Array<String>) Represents a Number set data type
1230
- # * `:bs` - (Array<String>) Represents a Binary set data type
1231
- # * `:action` - (String) Specifies how to perform the update. Valid
1232
- # values are PUT, DELETE, and ADD. The behavior depends on whether
1233
- # the specified primary key already exists in the table. If an item
1234
- # with the specified Key is found in the table: PUT - Adds the
1235
- # specified attribute to the item. If the attribute already exists,
1236
- # it is replaced by the new value. DELETE - If no value is
1237
- # specified, the attribute and its value are removed from the item.
1238
- # The data type of the specified value must match the existing
1239
- # value's data type. If a set of values is specified, then those
1240
- # values are subtracted from the old set. For example, if the
1241
- # attribute value was the set [a,b,c] and the DELETE action
1242
- # specified [a,c], then the final attribute value would be [b].
1243
- # Specifying an empty set is an error. ADD - If the attribute does
1244
- # not already exist, then the attribute and its values are added to
1245
- # the item. If the attribute does exist, then the behavior of ADD
1246
- # depends on the data type of the attribute: If the existing
1247
- # attribute is a number, and if Value is also a number, then the
1248
- # Value is mathematically added to the existing attribute. If Value
1249
- # is a negative number, then it is subtracted from the existing
1250
- # attribute. If you use ADD to increment or decrement a number
1251
- # value for an item that doesn't exist before the update, uses 0 as
1252
- # the initial value. In addition, if you use ADD to update an
1253
- # existing item, and intend to increment or decrement an attribute
1254
- # value which does not yet exist, uses 0 as the initial value. For
1255
- # example, suppose that the item you want to update does not yet
1256
- # have an attribute named itemcount, but you decide to ADD the
1257
- # number 3 to this attribute anyway, even though it currently does
1258
- # not exist. will create the itemcount attribute, set its initial
1259
- # value to 0, and finally add 3 to it. The result will be a new
1260
- # itemcount attribute in the item, with a value of 3. If the
1261
- # existing data type is a set, and if the Value is also a set, then
1262
- # the Value is added to the existing set. (This is a set operation,
1263
- # not mathematical addition.) For example, if the attribute value
1264
- # was the set [1,2], and the ADD action specified [3], then the
1265
- # final attribute value would be [1,2,3]. An error occurs if an Add
1266
- # action is specified for a set attribute and the attribute type
1267
- # specified does not match the existing set type. Both sets must
1268
- # have the same primitive data type. For example, if the existing
1269
- # data type is a set of strings, the Value must also be a set of
1270
- # strings. The same holds `true` for number sets and binary sets.
1271
- # This action is only valid for an existing attribute whose data
1272
- # type is number or is a set. Do not use ADD for any other data
1273
- # types. If no item with the specified Key is found: PUT - creates
1274
- # a new item with the specified primary key, and then adds the
1275
- # attribute. DELETE - Nothing happens; there is no attribute to
1276
- # delete. ADD - creates an item with the supplied primary key and
1277
- # number (or set of numbers) for the attribute value. The only data
1278
- # types allowed are number and number set; no other data types can
1279
- # be specified. Valid values include:
1280
- # * `ADD`
1281
- # * `PUT`
1282
- # * `DELETE`
1283
- # * `:expected` - (Hash<String,Hash>) A map of attribute/condition
1284
- # pairs. This is the conditional block for the UpdateItem operation.
1285
- # All the conditions must be met for the operation to succeed.
1286
- # * `:value` - (Hash) Specify whether or not a value already exists
1287
- # and has a specific content for the attribute name-value pair.
1288
- # * `:s` - (String) Represents a String data type
1289
- # * `:n` - (String) Represents a Number data type
1290
- # * `:b` - (String) Represents a Binary data type
1291
- # * `:ss` - (Array<String>) Represents a String set data type
1292
- # * `:ns` - (Array<String>) Represents a Number set data type
1293
- # * `:bs` - (Array<String>) Represents a Binary set data type
1294
- # * `:exists` - (Boolean) Causes to evaluate the value before
1295
- # attempting a conditional operation: If Exists is `true` , will
1296
- # check to see if that attribute value already exists in the table.
1297
- # If it is found, then the operation succeeds. If it is not found,
1298
- # the operation fails with a ConditionalCheckFailedException. If
1299
- # Exists is `false` , assumes that the attribute value does not
1300
- # exist in the table. If in fact the value does not exist, then the
1301
- # assumption is valid and the operation succeeds. If the value is
1302
- # found, despite the assumption that it does not exist, the
1303
- # operation fails with a ConditionalCheckFailedException. The
1304
- # default setting for Exists is `true` . If you supply a Value all
1305
- # by itself, assumes the attribute exists: You don't have to set
1306
- # Exists to `true` , because it is implied. returns a
1307
- # ValidationException if: Exists is `true` but there is no Value to
1308
- # check. (You expect a value to exist, but don't specify what that
1309
- # value is.) Exists is `false` but you also specify a Value. (You
1310
- # cannot expect an attribute to have a value, while also expecting
1311
- # it not to exist.) If you specify more than one condition for
1312
- # Exists, then all of the conditions must evaluate to `true` . (In
1313
- # other words, the conditions are ANDed together.) Otherwise, the
1314
- # conditional operation will fail.
1315
- # * `:return_values` - (String) Use ReturnValues if you want to get the
1316
- # item attributes as they appeared either before or after they were
1317
- # updated. For UpdateItem, the valid values are: NONE - If
1318
- # ReturnValues is not specified, or if its value is NONE, then
1319
- # nothing is returned. (This is the default for ReturnValues.)
1320
- # ALL_OLD - If UpdateItem overwrote an attribute name-value pair,
1321
- # then the content of the old item is returned. UPDATED_OLD - The old
1322
- # versions of only the updated attributes are returned. ALL_NEW - All
1323
- # of the attributes of the new version of the item are returned.
1324
- # UPDATED_NEW - The new versions of only the updated attributes are
1325
- # returned. Valid values include:
1326
- # * `NONE`
1327
- # * `ALL_OLD`
1328
- # * `UPDATED_OLD`
1329
- # * `ALL_NEW`
1330
- # * `UPDATED_NEW`
1331
- # * `:return_consumed_capacity` - (String) Valid values include:
1332
- # * `TOTAL`
1333
- # * `NONE`
1334
- # * `:return_item_collection_metrics` - (String) Valid values include:
1335
- # * `SIZE`
1336
- # * `NONE`
1337
- # @return [Core::Response]
1338
- # The #data method of the response object returns
1339
- # a hash with the following structure:
1340
- #
1341
- # * `:attributes` - (Hash<String,Hash>)
1342
- # * `:s` - (String)
1343
- # * `:n` - (String)
1344
- # * `:b` - (String)
1345
- # * `:ss` - (Array<String>)
1346
- # * `:ns` - (Array<String>)
1347
- # * `:bs` - (Array<Blob>)
1348
- # * `:consumed_capacity` - (Hash)
1349
- # * `:table_name` - (String)
1350
- # * `:capacity_units` - (Numeric)
1351
- # * `:item_collection_metrics` - (Hash)
1352
- # * `:item_collection_key` - (Hash<String,Hash>)
1353
- # * `:s` - (String)
1354
- # * `:n` - (String)
1355
- # * `:b` - (String)
1356
- # * `:ss` - (Array<String>)
1357
- # * `:ns` - (Array<String>)
1358
- # * `:bs` - (Array<Blob>)
1359
- # * `:size_estimate_range_gb` - (Array<Float>)
1360
-
1361
- # @!method update_table(options = {})
1362
- # Calls the UpdateTable API operation.
1363
- # @param [Hash] options
1364
- #
1365
- # * `:table_name` - *required* - (String) The name of the table to be
1366
- # updated.
1367
- # * `:provisioned_throughput` - *required* - (Hash)
1368
- # * `:read_capacity_units` - *required* - (Integer) The maximum
1369
- # number of strongly consistent reads consumed per second before
1370
- # returns a ThrottlingException. For more information, see
1371
- # Specifying Read and Write Requirements .
1372
- # * `:write_capacity_units` - *required* - (Integer) The maximum
1373
- # number of writes consumed per second before returns a
1374
- # ThrottlingException. For more information, see Specifying Read
1375
- # and Write Requirements .
1376
- # @return [Core::Response]
1377
- # The #data method of the response object returns
1378
- # a hash with the following structure:
1379
- #
1380
- # * `:table_description` - (Hash)
1381
- # * `:attribute_definitions` - (Array<Hash>)
1382
- # * `:attribute_name` - (String)
1383
- # * `:attribute_type` - (String)
1384
- # * `:table_name` - (String)
1385
- # * `:key_schema` - (Array<Hash>)
1386
- # * `:attribute_name` - (String)
1387
- # * `:key_type` - (String)
1388
- # * `:table_status` - (String)
1389
- # * `:creation_date_time` - (Time)
1390
- # * `:provisioned_throughput` - (Hash)
1391
- # * `:last_increase_date_time` - (Time)
1392
- # * `:last_decrease_date_time` - (Time)
1393
- # * `:number_of_decreases_today` - (Integer)
1394
- # * `:read_capacity_units` - (Integer)
1395
- # * `:write_capacity_units` - (Integer)
1396
- # * `:table_size_bytes` - (Integer)
1397
- # * `:item_count` - (Integer)
1398
- # * `:local_secondary_indexes` - (Array<Hash>)
1399
- # * `:index_name` - (String)
1400
- # * `:key_schema` - (Array<Hash>)
1401
- # * `:attribute_name` - (String)
1402
- # * `:key_type` - (String)
1403
- # * `:projection` - (Hash)
1404
- # * `:projection_type` - (String)
1405
- # * `:non_key_attributes` - (Array<String>)
1406
- # * `:index_size_bytes` - (Integer)
1407
- # * `:item_count` - (Integer)
1408
-
1409
- # end client methods #
1410
-
1411
- define_client_methods('2012-08-10')
1412
-
17
+ # ClientV2 is now deprecated. To use the lastest Amazon DynamoDB
18
+ # api version, pass the :api_version option to AWS::DynamoDB::Client.new
19
+ #
20
+ # AWS::DynamoDB::Client.new(:api_version => '2012-08-10')
21
+ # #=> #<AWS::DynamoDB::Client::V20120810>
22
+ #
23
+ # # defaults to the oldest api version
24
+ # AWS::DynamoDB::Client.new
25
+ # #=> #<AWS::DynamoDB::Client::V20111205>
26
+ #
27
+ # @api private
28
+ class ClientV2
29
+
30
+ DEPRECATION_MSG = "DEPRECATION WARNING: AWS::DynamoDB::ClientV2 is deprecated, use AWS::DynamoDB::Client.new(:api_version => '2012-08-10')"
31
+
32
+ class << self
33
+
34
+ extend Core::Deprecations
35
+
36
+ def new(options = {})
37
+ Client.new(options.merge(:api_version => '2012-08-10'))
38
+ end
39
+ deprecated :new, :message => DEPRECATION_MSG
40
+
41
+ end
1413
42
  end
1414
43
  end
1415
44
  end