13 releases

0.8.2 Nov 8, 2021
0.8.0 Apr 8, 2021
0.7.4 Mar 8, 2021
0.7.3 Aug 11, 2020
0.5.4 Jul 14, 2019

#598 in Encoding

Download history 11729/week @ 2024-06-13 13839/week @ 2024-06-20 15474/week @ 2024-06-27 7119/week @ 2024-07-04 6136/week @ 2024-07-11 7124/week @ 2024-07-18 6022/week @ 2024-07-25 6527/week @ 2024-08-01 5041/week @ 2024-08-08 6418/week @ 2024-08-15 4283/week @ 2024-08-22 310/week @ 2024-08-29 496/week @ 2024-09-05 199/week @ 2024-09-12 242/week @ 2024-09-19 120/week @ 2024-09-26

1,111 downloads per month
Used in sonnerie

MIT license

87KB
2K SLoC

rust-shardio

Crates.io Downloads Crates.io Version Crates.io License Build Status Coverage Status API Docs

Library for out-of-memory sorting of large datasets which need to be processed in multiple map / sort / reduce passes.

You write a stream of items of type T implementing Serialize and Deserialize to a ShardWriter. The items are buffered, sorted according to a customizable sort key, then serialized to disk in chunks with serde + lz4, while maintaining an index of the position and key range of each chunk. You use a ShardReader to stream through a item in a selected interval of the key space, in sorted order.

See Docs for API and examples.

Note: Enable the 'full-test' feature in Release mode to turn on some long-running stress tests.

Dependencies

~2.3–3.5MB
~67K SLoC