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

Closed
1 of 2 tasks
bengaudiosi-toast opened this issue Sep 26, 2024 · 2 comments
Closed
1 of 2 tasks
Assignees
Labels
feature-request A feature should be added or improved. service-api This issue is due to a problem in a service API, not the SDK implementation.

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
@RanVaknin
Copy link

Hi @bengaudiosi-toast ,

Thanks for opening the issue. This feature you are asking for is not an SDK feature but rather an API feature request. The SDK is a client and there has to be server side support for this feature for it to exist in the SDK.

I have created an internal feature request with the DDB team on your behalf (internal PFR ID a2vRU000000GfSDYA0) however we do not have visibility to when / if this will get implemented. My suggestion is to keep an eye out for announcements from DDB / our release notes to see if this was added.

Since this is not directly actionable by the SDK team, I'm going to go ahead and close this.

Thanks again,
Ran~

@RanVaknin RanVaknin self-assigned this Dec 9, 2024
@RanVaknin RanVaknin added service-api This issue is due to a problem in a service API, not the SDK implementation. and removed needs-triage This issue or PR still needs to be triaged. labels Dec 9, 2024
@RanVaknin RanVaknin closed this as not planned Won't fix, can't repro, duplicate, stale Dec 9, 2024
Copy link

github-actions bot commented Dec 9, 2024

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.

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. service-api This issue is due to a problem in a service API, not the SDK implementation.
Projects
None yet
Development

No branches or pull requests

2 participants