lance-format / lance-format/lance
Always update zone map index during write time
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 7.1k
- Forks
- 852
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 272
Description
With zone map index now added, I think one important feature we desire is to always update the index as a part of write. This is quite important for getting good quality splits for the get_splits API. If zone map is not up to date, then get_splits will not be as efficient for the unindexed fragments.
Currently, we rely on a separated training step to train the zone map index. It should be possible to directly update a zone map index not matter if we are doing insert or merge-insert or compaction. The file writer can collect stats as the data is written, and we can aggregate the new zones during commit time and commit it.
One key consideration is performance, we don't want to slow down the write too much because we need to update the index along the way. I think one way to solve that is to buffer the new zone maps as deltas, these zone maps do not even need to be flushed to disk, instead they can be stored as a part of the index details in the manifest, and we only trigger a merge asynchronously or based on some write threshold.
Would be curious about the thoughts around this topic @westonpace @HaochengLIU
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No files, tests, or entry points are named. Start by locating the zone map index, file-writer, commit, manifest, and get_splits implementations; define how insert, merge-insert, and compaction update index deltas, then validate that writes remain performant and get_splits sees current zones.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100