aws-dax-go
aws-dax-go copied to clipboard
use aws-sdk-go-v2
Issue #, if available:
#2
Description of changes:
use aws-sdk-go-v2 in the entire code. If you have any questions, please feel free to ask.
Summary of the changes
Although there are numerous changes in the code, I have made the following modifications:
- Import aws-sdk-go-v2, but no import aws-sdk-go
- All error is wrapped by using aws/smithy-go
- Compatible dynamodb V2 API (see also:
dax.DynamoDBAPI
) - Functions such as
Retryer
use aws-sdk-go-v2. - For functionalities that are difficult to maintain compatibility with, removed them temporarily (e.g.,
PutItemRequest
,BatchGetItemPages
) - Of course all test passed
Verification
I have created a validation repository to confirm if the changed code is actually usable. https://github.com/shamaton/aws-dax-go-v2-test
- API: GetItem
- API: PutItem (also case: ConditionalExpression)
- API: UpdateItem
- API: DeleteItem
- API: Query
- API: Scan (also Count)
- API: BatchGetItems
- API: BatchWriteItems
- API: TransactGetItems
- Checked if the DAX cache is enable
The future of this pull request
I think there are the following options:
- Merge this pull request into the master branch.
- Merge the changes of this pull request into another branch, such as
v2
, and proceed with the operation. - Create a separate repository to make it usable, for example,
aws/aws-dax-go-v2
. - Reject this pull request (unfortunate decision).
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.