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

Implement return values for enhanced PutItem #2710

Merged
merged 2 commits into from
Sep 16, 2021

Conversation

dagnir
Copy link
Contributor

@dagnir dagnir commented Sep 10, 2021

Motivation and Context

Requested feature.

Description

This commit introduces DynamoDbTable#putItemWithResponse() that allows customers
to specify additional parameters on the request such as ReturnValues to get
additional information the service response.

Relates to #1918, #2095

Testing

  • Unit tests
  • Integration tests

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have read the CONTRIBUTING document
  • Local run of mvn install succeeds
  • My code follows the code style of this project
  • My change requires a change to the Javadoc documentation
  • I have updated the Javadoc documentation accordingly
  • I have read the README document
  • I have added tests to cover my changes
  • All new and existing tests passed
  • A short description of the change has been added to the CHANGELOG
  • My change is to implement 1.11 parity feature and I have updated LaunchChangelog

License

  • I confirm that this pull request can be released under the Apache 2 license

@dagnir
Copy link
Contributor Author

dagnir commented Sep 14, 2021

The flagged bug is a false positive:

        if (request.left().isPresent()) {
            requestBuilder = addPlainPutItemParameters(requestBuilder, request.left().get());

It says

Call "Optional#isPresent()" before accessing the value.

But we are doing that.

@dagnir dagnir force-pushed the putitem-returnvalues branch 3 times, most recently from 84f5b62 to fbbe98e Compare September 14, 2021 20:28
@dagnir dagnir changed the title WIP PutItem with response Implement return values for enhanced PutItem Sep 14, 2021
@dagnir dagnir force-pushed the putitem-returnvalues branch from fbbe98e to 611120c Compare September 14, 2021 20:34
@dagnir dagnir marked this pull request as ready for review September 14, 2021 22:52
@dagnir dagnir force-pushed the putitem-returnvalues branch from 611120c to b38bab9 Compare September 15, 2021 19:50
This commit introduces DynamoDbTable#putItemWithResponse() that allows customers
to specify additional parameters on the request such as ReturnValues to get
additional information the service response.

Relates to aws#1918
@dagnir dagnir force-pushed the putitem-returnvalues branch from b38bab9 to 40ca5f2 Compare September 15, 2021 20:01
Copy link
Contributor

@millems millems left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one minor comment

@sonarcloud
Copy link

sonarcloud bot commented Sep 16, 2021

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 5 Code Smells

91.9% 91.9% Coverage
0.0% 0.0% Duplication

@dagnir dagnir merged commit 77a1f0e into aws:master Sep 16, 2021
@dagnir dagnir deleted the putitem-returnvalues branch September 16, 2021 17:45
@dagnir dagnir mentioned this pull request Sep 16, 2021
13 tasks
aws-sdk-java-automation added a commit that referenced this pull request Oct 5, 2023
…ef6b7bb62

Pull request: release <- staging/841c5502-cbe0-48e3-bce9-024ef6b7bb62
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.

2 participants