zstd compressor and decompressor use the same configuration
- Lingua principale
- Java
- Stelle
- 3.1k
- Fork
- 1.6k
- Merge medio
- 3g 12h
- PR unite (30g)
- 33
Descrizione
I use spark to rewrite the parquet files that are compressed by zstd. And the parquet version is 1.12.2. I want to read the parquet files compressed by level 3 and compress them on another level. But the level can't be changed.
After I check the source, I found the problem was the codec was cached, and the configuration will not be updated:
I think the problem is important. I found it when I try to use a different level to compaction the files in the iceberg table. Asynchronous rewriting with a higher level can lead to higher compression ratio. This is important to save storage costs.
**Reporter**: [Peidian Li](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=lipeidian)
**Note**: *This issue was originally created as [PARQUET-2152](https://issues.apache.org/jira/browse/PARQUET-2152). Please see the [migration documentation](https://issues.apache.org/jira/browse/PARQUET-2502) for further details.*
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Inizia da parquet-hadoop/src/main/java/org/apache/parquet/hadoop/CodecFactory.java, in particolare dai punti relativi alla cache alle righe 144 e 226. Traccia il modo in cui vengono messe in cache le configurazioni del compressore e del decompressore e conferma che una riscrittura possa usare un livello di compressione Zstandard diverso. Il lavoro è completato quando il livello richiesto non è più bloccato da una configurazione del codec precedentemente memorizzata nella cache, aggiungendo una copertura di regressione se i test circostanti individuano una posizione appropriata.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- java, spark
- Ambito
- data-engineering
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 45/100