[Java] BaseVariableWidthVector only supports 1 GiB through safe interfaces
- Vorherrschende Sprache
- Java
- Sterne
- 94
- Forks
- 152
- Ø Merge
- 3 T. 16 Std.
- Gemergte PRs (30 T.)
- 11
Beschreibung
### Describe the bug, including details regarding any error messages, version, and platform.
https://github.com/apache/arrow/pull/13815 fixed an issue with a misleading error caused by going over the 2GiB limit of a variable width vector, but it also introduced a 1 GiB limit when using the safe interfaces. Basically whenever you try to add data beyond 1 GiB, the vector will try to double itself to the next power of two, which would be 2147483648, which is greater than Integer.MAX_VALUE which is 2147483647, thus throwing a OversizedAllocationException. This effectively limits the total size allowed in the buffer to 1 GiB, even though it should only really be bound by the max offset being less than Integer.MAX_VALUE.
See https://github.com/apache/spark/pull/39572#issuecomment-1383195213 and the comment above it for how I could recreate the issue.
### Component(s)
Java
Beitragsleitfaden
Rechercherichtung
Reproduziere den 1-GiB-Fehler anhand des in der verlinkten Apache Spark-Diskussion beschriebenen Szenarios und verfolge anschließend das Kapazitätswachstum in BaseVariableWidthVector und seinen sicheren Schnittstellen. Die Korrektur ist abgeschlossen, wenn Daten variabler Breite über 1 GiB hinaus wachsen können, ohne eine ungültige 2-GiB-Allokation zu versuchen, und dabei weiterhin das Offset-Limit Integer.MAX_VALUE eingehalten wird; füge einen Regressionstest für diese Grenze hinzu.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- java
- Bereich
- data-engineering
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 45/100