Officially, This is the example code using java:
BatchGetResultPageIterable batchResults = enhancedClient.batchGetItem(r -> r.addReadBatch(ReadBatch.builder(Customer.class)
.mappedTableResource(customerTable)
.addGetItem(key1)
.addGetItem(key2)
.addGetItem(key3)
.build()));
What is the way to achieve that but sending a list of keys ? The library that I have to use is: https://github.com/aws/aws-sdk-java-v2/tree/master/services-custom/dynamodb-enhanced