Expanded support for map type in DynamoDB #339
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
For #308
This PR provides a UpdateExpressionUpdateAttributes method on Table that will allow us to support arbitrary UpdateExpressions to the underlying UpdateItem API endpoint.
The existing UpdateAttributes method on Table could potentially be modified to support a limited subset of UpdateExpressions, but it can't support semantics like "SET #key1.#key2=:val1" that are permitted by the DynamoDB API. Adding a new method rather than extending the existing interface will allow consuming code to avoid the complexity of writing an UpdateExpression unless it's actually needed to express operations on fields of a map (or multiple operations such as a SET and DELETE in the same call). Examples are provided in the associated test code.
Includes:
I've run the full dynamodb package's test suite via
go test -check.vv -amazon -local