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

transactWriteItems can use ReturnValues to get written items on successful write #5629

Open
1 of 2 tasks
bengaudiosi-toast opened this issue Sep 26, 2024 · 0 comments
Open
1 of 2 tasks
Labels
feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged.

Comments

@bengaudiosi-toast
Copy link

Describe the feature

Right now, if you have a successful transact write items request, you need to read that value back to get its new state.

Other write operations, like PutItemEnhancedRequest and UpdateItemEnhancedRequest, allow you specify ReturnValues as an option to get these values back as part of the response for no additional read capacity.

Use Case

When we utilize @DynamoDbVersionAttribute, version numbers for optimistic locking are automatically updated as part of the client call.

We can manually update these ourselves client side to have the updated version, or re-read the object from the DB, but I'd rather the updated object could be included as part of the response.

Proposed Solution

The ReturnValues feature should also exist on the respective TransactPutItemEnhancedRequest and TransactUpdateItemEnhancedRequest requests, and any updated items should be included in the response if these values are set.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

AWS Java SDK version used

2.27.24

JDK version used

openjdk 17.0.9 2023-10-17 LTS

Operating System and version

macOS Sonoma 14.5

@bengaudiosi-toast bengaudiosi-toast added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Sep 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged.
Projects
None yet
Development

No branches or pull requests

1 participant