aws / aws/aws-sdk-java-v2

DynamoDB Enhanced: Support other java.time types

Aperta
#4,707 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
dynamodb-enhanced feature-request p2
Lingua principale
Java
Stelle
2.6k
Fork
1k
Merge medio
2g 9h
PR unite (30g)
51

Descrizione

### Describe the feature

As of 2.21.25, the DynamoDB Enhanced client supports out-of-the-box a large portion of the `java.time` value types, such as `Instant`, `LocalTime`, and even `ZoneId`. However, there are some other types that do not have built-in converters.

### Use Case

I am writing a table to track usage for billing purposes, and one of my columns is the billing month, represented in Java code by `java.time.YearMonth`. The naive string representation is simply "YYYY-mm", which is exactly what I want in my column, but `YearMonth` can't be mapped without extra configuration.

### Proposed Solution

Add converters for all remaining `java.time` value types, particularly including:
- `Month`
- `MonthDay`
- `Period`
- `Year`
- `YearMonth`

All of these types have simple, clearly-defined ISO-8601 representations that are their native defaults.

### 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.21.25

### JDK version used

openjdk version "11.0.18" 2023-01-17

### Operating System and version

Gentoo Linux

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia in DynamoDB Enhanced client individuando i converter java.time esistenti e i relativi test. Esamina come sono rappresentati i tipi elencati Month, MonthDay, Period, Year e YearMonth, quindi aggiungi test che dimostrino che ciascuno usa il proprio formato ISO-8601 nativo e può essere mappato senza configurazione aggiuntiva.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
java
Ambito
databases
Tipo di issue
Funzionalità
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
48/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.