aws-sdk-dynamodb 1.94.0 → 1.95.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8c015738e9e83b6ff04b0d5beafc2d214ed8ba1af835466ffd86f9b718a22d15
4
- data.tar.gz: 5020de3b5d59e92ca6cf22088cfeb7eba48c22ca94e8a7bbf0e45ef387e01e61
3
+ metadata.gz: 19558d8dc5f1dee38d74213a6b1d8ff48a912c4cf03f515109c116edb64975f2
4
+ data.tar.gz: 03d51f2db1243f614c3f607b5e945b6f0ab8f147726714bfcd1cf9239cf89ac2
5
5
  SHA512:
6
- metadata.gz: 935b64c71522b94691be748126ed9e8a90848db8d7358797ca9d695a054250c94c35ebdbc3eecff2fe8546e04f4d573ece6de2558c363857f049b68fb3f8f3ed
7
- data.tar.gz: f21bb69f9c5233e830552998cfc8b15b1f5045171b714c74ec2d5745de5600e30ac87d4ff964c889a6839c691589e1d04c765641bea749073f223bfadd7cdfc4
6
+ metadata.gz: 68f77b30a55e8ae1ebc78cef445eceab72fed673eaab1d9661a267b7db97c527df2132e4bde8eeafcf5cf1bb59efea7706efe81d08ecc46027eb90825a2da685
7
+ data.tar.gz: 2d1c6b250f6b2f4b6de5ea8c31901843b49119359c341cad82d6a03aa74777abd611d47f3fb4c881c38c3bc5bf05b6f18d054cc9718ca0e94bdd1691bc1a70e8
data/CHANGELOG.md CHANGED
@@ -1,6 +1,13 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.95.0 (2023-09-27)
5
+ ------------------
6
+
7
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
8
+
9
+ * Feature - Simple attributes conversion for item data returned in `ConditionalCheckFailedException` and other exceptions. (Breaking change / bug fix)
10
+
4
11
  1.94.0 (2023-09-26)
5
12
  ------------------
6
13
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.94.0
1
+ 1.95.0
@@ -7861,7 +7861,7 @@ module Aws::DynamoDB
7861
7861
  params: params,
7862
7862
  config: config)
7863
7863
  context[:gem_name] = 'aws-sdk-dynamodb'
7864
- context[:gem_version] = '1.94.0'
7864
+ context[:gem_version] = '1.95.0'
7865
7865
  Seahorse::Client::Request.new(handlers, context)
7866
7866
  end
7867
7867
 
@@ -83,11 +83,11 @@ module Aws
83
83
  # # note that the request `:key` had to be type prefixed
84
84
  # resp = dynamodb.get(table_name: 'aws-sdk', key: { 'id' => { s: 'uuid' }})
85
85
  # resp.item
86
- # # {
87
- # # "id"=> <struct s='uuid', n=nil, b=nil, ss=nil, ns=nil, bs=nil, m=nil, l=nil, null=nil, bool=nil>
88
- # # "age"=> <struct s=nil, n="35", b=nil, ss=nil, ns=nil, bs=nil, m=nil, l=nil, null=nil, bool=nil>
89
- # # ...
90
- # # }
86
+ # {
87
+ # "id"=> <struct s='uuid', n=nil, b=nil, ss=nil, ns=nil, bs=nil, m=nil, l=nil, null=nil, bool=nil>
88
+ # "age"=> <struct s=nil, n="35", b=nil, ss=nil, ns=nil, bs=nil, m=nil, l=nil, null=nil, bool=nil>
89
+ # ...
90
+ # }
91
91
  #
92
92
  class SimpleAttributes < Seahorse::Client::Plugin
93
93
 
@@ -119,12 +119,15 @@ their types specified, e.g. `{ s: 'abc' }` instead of simply
119
119
  @handler.call(context).on(200) do |response|
120
120
  response.data = translate_output(response)
121
121
  end
122
+ rescue Aws::Errors::ServiceError => e
123
+ e.data = translate_error_data(context, e.data)
124
+ raise e
122
125
  end
123
126
 
124
127
  private
125
128
 
126
129
  def translate_input(context)
127
- if shape = context.operation.input
130
+ if (shape = context.operation.input)
128
131
  ValueTranslator.new(shape, :marshal).apply(context.params)
129
132
  else
130
133
  context.params
@@ -132,13 +135,24 @@ their types specified, e.g. `{ s: 'abc' }` instead of simply
132
135
  end
133
136
 
134
137
  def translate_output(response)
135
- if shape = response.context.operation.output
138
+ if (shape = response.context.operation.output)
136
139
  ValueTranslator.new(shape, :unmarshal).apply(response.data)
137
140
  else
138
141
  response.data
139
142
  end
140
143
  end
141
144
 
145
+ def translate_error_data(context, error_data)
146
+ shape = context.operation.errors.find do |e|
147
+ error_data.is_a?(e.shape.struct_class)
148
+ end
149
+ if shape
150
+ ValueTranslator.new(shape, :unmarshal).apply(error_data)
151
+ else
152
+ error_data
153
+ end
154
+ end
155
+
142
156
  end
143
157
 
144
158
  # @api private
@@ -54,6 +54,6 @@ require_relative 'aws-sdk-dynamodb/customizations'
54
54
  # @!group service
55
55
  module Aws::DynamoDB
56
56
 
57
- GEM_VERSION = '1.94.0'
57
+ GEM_VERSION = '1.95.0'
58
58
 
59
59
  end
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.94.0
4
+ version: 1.95.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-26 00:00:00.000000000 Z
11
+ date: 2023-09-27 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.177.0
22
+ version: 3.184.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.177.0
32
+ version: 3.184.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement