DynamoDB Enhanced Client: batch writes
- Lingua principale
- Java
- Stelle
- 2.6k
- Fork
- 1k
- Merge medio
- 2g 9h
- PR unite (30g)
- 51
Descrizione
### Describe the feature
Requested feature: `batchPutItem(Collection)` and `batchUpdateItem(Collection)` methods on `DynamoDbTable`.
### Use Case
The low-level client supports batch transactional writes, and the Enhanced client works by mapping POJOs onto low-level operations. I would like to write a series of records transactionally from POJOs, but the Enhanced client only supports single-record operations. Instead, I want to prepare the records to be saved and save them as a batch.
### Proposed Solution
`PutItemOperation` (with the other `TableOperation`s) generates a `PutItemRequest`, and the low-level client already supports the `batchWriteItem` operation that takes multiple `PutItemRequest`s and batches them. All of the existing logic for the Enhanced client could remain in place with a scatter-gather implementation that collects the generated requests and executes them via `batchWriteItem`.
### Other Information
_No response_
### Acknowledgements
- [x] I may be able to implement this feature request
- [ ] This feature might incur a breaking change
### AWS Java SDK version used
2.17.260
### JDK version used
OpenJDK 64-Bit Server VM AdoptOpenJDK-11.0.11+9 (build 11.0.11+9, mixed mode)
### Operating System and version
Gentoo Linux
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia leggendo DynamoDbTable, l'implementazione esistente di PutItemOperation e le altre implementazioni di TableOperation, quindi confronta le richieste generate con l'operazione di basso livello batchWriteItem. Definisci il comportamento di batchPutItem(Collection) e batchUpdateItem(Collection) per la raccolta delle richieste mappate e la loro esecuzione in batch; il lavoro è completato quando è possibile scrivere POJO tramite l'Enhanced client usando i metodi batch richiesti.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- aws, java
- Ambito
- cloud, databases
- Tipo di issue
- Funzionalità
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 35/100