lance-format / lance-format/lance

Support Tiered in-memory + SSD cache for data

Open
#6,483 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rust
Stars
7.1k
Forks
852
Avg merge
3d 18h
Merged PRs (30d)
272

Description

Having an inmemory + SSD cache for data files could be very useful in the lance API.

Heres how it might look like

ds = lance.dataset(                                                                                                                     
      "s3://bucket/nuscenes.lance",                                                                                                       
      storage_options={                                                                                                                   
          "ssd_cache_dir": "/mnt/nvme/lance_cache",                                                                        
          "ssd_cache_size_mb": 100_000,
           "max_memory_cache_mb":1000,                                                    
      }
                                                                                                                                   
  ) 

How it should work:

Two-tier cache modelled after the Velox caching system:

Remote GCS/S3                                                                                                                           
      │  fetch on miss                                                                                                                    
      ▼                                                                                                                                   
Memory cache (hot, bounded)                                                                                                             
      │  evict to SSD when memory threshold hit                                                                                           
      ▼                                                                                                                                   
SSD cache (warm, bounded)                                                                                                               
      │  evict LRU when SSD limit hit                                                                                                     
      ▼                                                  
 Discard   

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the Lance API path that handles storage_options and the data-file fetching path. Compare the requested behavior with the Velox-style two-tier model described here. Done means supporting bounded memory and SSD caches, promoting data on misses, evicting from memory to SSD, and applying LRU eviction at the SSD limit.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend, cloud, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.