11 releases (breaking)

0.11.0 Oct 30, 2024
0.9.1 Jun 24, 2024
0.9.0 Nov 1, 2023
0.7.1 Jul 28, 2023
0.5.0 Oct 17, 2022

#80 in Compression

Download history 13786/week @ 2024-08-04 12246/week @ 2024-08-11 13770/week @ 2024-08-18 9203/week @ 2024-08-25 9789/week @ 2024-09-01 9853/week @ 2024-09-08 8351/week @ 2024-09-15 10819/week @ 2024-09-22 6515/week @ 2024-09-29 6574/week @ 2024-10-06 6669/week @ 2024-10-13 8129/week @ 2024-10-20 5733/week @ 2024-10-27 6421/week @ 2024-11-03 6517/week @ 2024-11-10 7585/week @ 2024-11-17

26,489 downloads per month
Used in foc

MIT license

380KB
3K SLoC

Rust MCAP library

A library for reading and writing Foxglove MCAP files. See the crate documentation for examples.

Design goals

  • Simple APIs: Users should be able to iterate over messages, with each automatically linked to its channel, and that channel linked to its schema. Users shouldn't have to manually track channel and schema IDs.

  • Performance: Writers shouldn't hold large buffers (e.g., the current chunk) in memory. Readers should support memory-mapped files to avoid needless copies and to let the OS do what it does best: loading and caching large files based on how you're actually reading them.

  • Resilience: Like MCAP itself, the library should let you recover every valid message from an incomplete file or chunk.

Building

By default this package will build with zstd compression support enabled. To build without the zstd dependency pass the --no-default-features flag:

cargo build --no-default-features

Dependencies

~2.4–9MB
~93K SLoC