Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

service/dynamodb/expression: Add expression building utility for DynamoDB #1527

Merged
merged 11 commits into from Sep 25, 2017

Conversation

jasdel
Copy link
Contributor

@jasdel jasdel commented Sep 14, 2017

Adds a new package, expression, to the SDK providing builder utilities to create DynamoDB expressions safely taking advantage of type safety.

Adds several new builders to construct specific DynamoDB Expression types. These builders can be combined together to retrieve the expression name, and value aliases, along with the formatted expression string for the given expression type.

Adds a runnable example under example/service/dynamodb/expression

* Initial commit

* write Base32Encoding test cases

* Implement numeric encoding instead of Base32

* Minor changes to satisfy golinter

* Implement unexported tree structure

* write tests

* Finish basic tests

* Use sprintf style aliasing

* Add BuildExpression method to ConditionBuilder

* Make change based on inline PR

* Add name to tests, comments for clarity, more index panic coverage
* implement AND and BETWEEN

* fix indentation on comments
* Implement rest of condition expression functions

* unexport consts

* get rid of unnecessary stringer implementations

* add tests for unexported functions

* Change error constants into string constants
* Implement rest of condition expression functions

* unexport consts

* get rid of unnecessary stringer implementations

* add tests for unexported functions

* initial implementation of projection

* Improve comments

* Improve tests

* Improve tests

* Improve comment grammar, get rid of iota constants and replace with string constants

* Implement projection expression and improve comments

* Change go build to 1.7

* make requested changes, specify that all paths are aliased

* Add test case for empty ProjectionBuilder

* Remove redundant line

* modify BuildOperand errors to use awserr

* Convert any error that users may cause into a typed error
Updates expressions, operand building, and errors returned.
* Implement Update Expression

* Remove unnecessary lines

* append ValueMode to SetValueBuilder modes for clarity
* Improve comments and add a doc.go

* get rid of the word user

* remove readme file and get rid of the word user

* reword builder struct to remove ambiguity

* make changes according to doc review
@jasdel jasdel changed the title service/dynamodb/expressions: Add expression building utility for DynamoDB service/dynamodb/expression: Add expression building utility for DynamoDB Sep 14, 2017
@jasdel jasdel requested a review from xibz September 15, 2017 23:14
@jasdel jasdel assigned jasdel and unassigned jasdel Sep 15, 2017
Minor updates to the the DynamoDB expression package's docs and examples.
@jasdel jasdel merged commit 792e96c into master Sep 25, 2017
@jasdel jasdel deleted the dynamodb-abstraction branch September 25, 2017 21:28
@awstools awstools mentioned this pull request Sep 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants