apache / apache/arrow-java

[Java] Dummy NPEs in DefaultAllocationManagerOption

Aperta
#258 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Type: enhancement
Lingua principale
Java
Stelle
94
Fork
152
Merge medio
3g 16h
PR unite (30g)
11

Descrizione

Looking at DefaultAllocationManagerOption [1], I see that we could prevent dummy NPEs when trying to convert an often not-set environment option into enums.
In my case, it was a bit painful to have this error, even if properly caught, because it was polluting debug when looking for unexpected NPEs. This was raising false positives.
 
I was wondering if you were open to a pull request to change this little inconvenience?
 
[1]

**Reporter**: [Olivier Peyrusse](https://issues.apache.org/jira/browse/ARROW-13697)

**Note**: *This issue was originally created as [ARROW-13697](https://issues.apache.org/jira/browse/ARROW-13697). Please see the [migration documentation](https://github.com/apache/arrow/issues/14542) for further details.*

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia leggendo java/memory/memory-core/src/main/java/org/apache/arrow/memory/DefaultAllocationManagerOption.java intorno alle righe 64-82, concentrandoti sulla conversione delle opzioni dell’ambiente non impostate in enums. Conferma il comportamento attuale per un’opzione non impostata e verifica che la gestione risultante non produca più NullPointerExceptions fittizie, preservando al contempo il comportamento previsto dell’opzione.

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

Valutazione

Stack tecnologico
java
Ambito
backend
Tipo di issue
Bug
Difficoltà
2/5
Tempo stimato
1-3 ore
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
42/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.