in src/main/scala/org/apache/pekko/persistence/dynamodb/journal/DynamoDBRecovery.scala [527:539]
def eventQuery(persistenceId: String, sequenceNr: Long) =
new QueryRequest()
.withTableName(JournalTable)
.withKeyConditionExpression(Key + " = :kkey")
.withExpressionAttributeValues(
Collections.singletonMap(":kkey", S(messagePartitionKey(persistenceId, sequenceNr))))
.withProjectionExpression("num")
.withConsistentRead(true)
private[dynamodb] def getAllPartitionSequenceNrs(persistenceId: String, sequenceNr: Long) = {
val request = eventQuery(persistenceId, sequenceNr)
dynamo.query(request).flatMap(getAllRemainingQueryItems(request, _))
}