-
Notifications
You must be signed in to change notification settings - Fork 654
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix AttributeValue marshaling and names in expressions (#1590)
Updates the `attributevalue` and `expression` package's handling of AttributeValue marshaling fixing several bugs in the packages. * Fixes #1569 `Inconsistent struct field name marshaled`. Fields will now be consistent with the EncoderOptions or DecoderOptions the Go struct was used with. Previously the Go struct fields would be cached with the first options used for the type. Causes subsequent usages to have the wrong field names if the encoding options used different TagKeys. * Fixes #645, #411 `Support more than string types for map keys`. Updates (un)marshaler to support number, bool, and types that implement encoding.Text(Un)Marshaler interfaces. * Fixes Support for expression Names with literal dots in name. Adds new function NameNoDotSplit to expression package. This function allows you to provide a literal expression Name containing dots. Also adds a new method to NameBuilder, AppendName, for joining multiple name path components together. Helpful for joining names with literal dots with subsequent object path fields. * Fixes bug with AttributeValue marshaler struct struct tag usage that caused TagKey to be ignored if the member had a struct tag with `dynamodbav` struct tag. Now both tags will be read as documented, with the TagKey struct tag options taking precedence.
- Loading branch information
Showing
28 changed files
with
1,671 additions
and
213 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"id": "2096a6be-b82d-44be-a4a4-69c197f6de40", | ||
"type": "feature", | ||
"description": "Add support for expression names with dots via new NameBuilder function NameNoDotSplit, related to [aws/aws-sdk-go#2570](https://github.com/aws/aws-sdk-go/issues/2570)", | ||
"modules": [ | ||
"feature/dynamodb/expression" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"id": "98a8c469-e1d6-4c9a-a06b-0e467ac61dd9", | ||
"type": "bugfix", | ||
"description": "Fixes [#1569](https://github.com/aws/aws-sdk-go-v2/issues/1569) inconsistent serialization of Go struct field names", | ||
"modules": [ | ||
"feature/dynamodb/attributevalue", | ||
"feature/dynamodbstreams/attributevalue" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"id": "db81731f-a3ab-450e-9ea3-535a0d4aaedd", | ||
"type": "feature", | ||
"description": "Fixes [#645](https://github.com/aws/aws-sdk-go-v2/issues/645), [#411](https://github.com/aws/aws-sdk-go-v2/issues/411) by adding support for (un)marshaling AttributeValue maps to Go maps key types of string, number, bool, and types implementing encoding.Text(un)Marshaler interface", | ||
"modules": [ | ||
"feature/dynamodb/attributevalue", | ||
"feature/dynamodbstreams/attributevalue" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.