40 releases (16 breaking)

new 0.19.2 Jul 24, 2024
0.18.3 Jul 2, 2024
0.16.0 Mar 1, 2024
0.14.2 Nov 18, 2023
0.4.0 Mar 29, 2023

#237 in Encoding

Download history 4362/week @ 2024-04-05 4561/week @ 2024-04-12 3755/week @ 2024-04-19 2606/week @ 2024-04-26 2627/week @ 2024-05-03 2820/week @ 2024-05-10 3200/week @ 2024-05-17 4101/week @ 2024-05-24 3013/week @ 2024-05-31 2144/week @ 2024-06-07 2972/week @ 2024-06-14 2916/week @ 2024-06-21 2860/week @ 2024-06-28 2907/week @ 2024-07-05 3732/week @ 2024-07-12 2366/week @ 2024-07-19

12,242 downloads per month
Used in 2 crates

Apache-2.0

765KB
18K SLoC

dbn

build Documentation license Current Crates.io Version

The official crate for working with Databento Binary Encoding (DBN). For more information about DBN, read our introduction to DBN.

Check out the databento crate for the official Databento Rust client.

Installation

To add the crate to an existing project, run the following command:

cargo add dbn

Usage

To read a DBN file with MBO data and print each row:

use dbn::{
    decode::dbn::Decoder,
    record::MboMsg,
};
use streaming_iterator::StreamingIterator;

let mut dbn_stream = Decoder::from_zstd_file("20201228.dbn.zst")?.decode_stream::<MboMsg>()?;
while let Some(mbo_msg) = dbn_stream.next() {
    println!("{mbo_msg:?}");
}

Documentation

See the docs for more detailed usage.

License

Distributed under the Apache 2.0 License.

Dependencies

~6–9MB
~159K SLoC