Improve SnappyCompressor buffer expansion performance
- 主要言語
- Java
- スター
- 3.1k
- フォーク
- 1.6k
- 平均マージ
- 3日 12時間
- マージ済み PR(30日)
- 33
説明
The existing implementation of SnappyCompressor will only allocate enough bytes for the buffer passed into setInput(). This leads to suboptimal performance when there are patterns of writes that cause repeated buffer expansions. In the worst case it must copy the entire buffer for every single invocation of setInput()
Instead of allocating a buffer of size current + write length, there should be an expansion strategy that reduces the amount of copying required.
**Reporter**: [Andrew Baranec](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=abaranec)
**Note**: *This issue was originally created as [PARQUET-2184](https://issues.apache.org/jira/browse/PARQUET-2184). Please see the [migration documentation](https://issues.apache.org/jira/browse/PARQUET-2502) for further details.*
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
調査の方向性
Locate SnappyCompressor and its setInput() implementation, then inspect how buffer allocation and copying behave across repeated writes. The work is done when buffer expansion avoids copying the entire buffer on every invocation while preserving the compressor's existing input behavior.
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- performance
- issue の種類
- リファクタリング
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100