apache / apache/iceberg-python
Add support for bucket expression to table scans
- 主要言語
- Python
- スター
- 1.1k
- フォーク
- 581
- 平均マージ
- 1日 17時間
- マージ済み PR(30日)
- 78
説明
### Feature Request / Improvement
For time partitioning, we can express time range expressions and they lead to partition pruning when planning an Arrow scan:
```py
scan = table.scan(
row_filter=And(
GreaterThanOrEqual("event_ts", start),
LessThan("event_ts", end),
)
)
arrow_table = scan.to_arrow()
```
It would be useful to be able to filter by other hidden partitioning transforms, such as buckets -- e.g. filtering on `bucket[16](user_id) in {0, 1, 2, 3}`, and getting partition pruning whenever possible based on the underlying table partitioning specs (falling back to filtering rows when files cannot be pruned).
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
調査の方向性
issue に記載されているエントリポイント table.scan と scan.to_arrow から開始し、Arrow のパーティションプルーニングに使用されている既存の時間範囲式の処理を追跡します。パーティション仕様と行フィルターがどのように適用されるかを確認します。bucket[16](user_id) のようなバケット式で、可能な場合はファイルをプルーニングし、不可能な場合は行フィルタリングにフォールバックできれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- python
- 領域
- databases
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 活発
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 55/100