meilisearch / grenad

Tools to sort, merge, write, and read immutable key-value pairs :tomato:
https://docs.rs/grenad
MIT License
25 stars 3 forks source link

Make all the tempfile dependency optinal by patching the sorter #9

Closed Kerollmops closed 3 years ago

Kerollmops commented 3 years ago

The Sorter should use a provided function to get its temp file or equivalent, the output type is only required to be io::Write + io::Read + Seek, a Cursor<Vec<u8>> could also do the job.

Allowing the sorter to use a type that does not write to disk can help introduce miri in the CI tests. Also, some systems do not use the filesystem, I think of no_std targets, we could provide a compatible version (note that we need alloc).