Skip to content

Conversation

@LeeroyHannigan
Copy link

Java: Add SDK v2 version of DocumentAPILocalSecondaryIndexExample in DynamoDB

This pull request adds an AWS SDK for Java v2 version of the DocumentAPILocalSecondaryIndexExample to the javav2 directory. The example demonstrates how to:

  • Create a DynamoDB table with local secondary indexes
  • Load data into the table
  • Query the table with and without indexes
  • Use projection expressions to limit returned attributes
  • Delete the table

The v2 implementation uses the low-level DynamoDbClient API with builder patterns, replacing the v1 Document API which has no direct equivalent in SDK v2.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions github-actions bot added Java-v1 This issue relates to the AWS SDK for Java V1 Java-v2 This issue relates to the AWS SDK for Java V2 labels Dec 17, 2025
@rlhagerm rlhagerm requested a review from scmacdon December 17, 2025 14:29
Copy link
Contributor

@scmacdon scmacdon left a comment

Choose a reason for hiding this comment

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

This example looks good.

@scmacdon scmacdon added the On Call Review needed This work needs an on-call review label Dec 18, 2025
@scmacdon scmacdon removed the On Call Review needed This work needs an on-call review label Dec 18, 2025
Copy link
Contributor

@scmacdon scmacdon left a comment

Choose a reason for hiding this comment

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

There are tags in the Java classes that have no closing tags. For example - // snippet-start:[dynamodb.java.codeexample.DocumentAPILocalSecondaryIndexExample] . All tags must be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Java-v1 This issue relates to the AWS SDK for Java V1 Java-v2 This issue relates to the AWS SDK for Java V2

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants