Zip Files as (Simple) Key-Value Stores
benjamincongdon.me·1d
🏺ZIP Archaeology
Preview
Report Post

I recently encountered a fun performance problem. Consider the following:

  • You need to distribute a key-value dataset with string keys and opaque value blobs in the 100B - 1MB range.
  • There are on the order of 10k keys to distribute.
  • Critically, you are in a constrained memory environment where you do not have enough memory to load all the blobs into memory at one time. You do, however, have enough memory to load all the keys and a small amount of metadata, if you want.
  • The key access pattern on the data is random.
  • The workload is entirely read-only.
  • You get to choose the file format and reader, but you must be able to disseminate this whole structure as one file.
  • Due to environment restrictions, you can’t use mmap to load files into memory.

I’ve heard the good…

Similar Posts

Loading similar posts...