33 releases (14 breaking)

0.17.1 Apr 3, 2024
0.16.0 Mar 1, 2024
0.14.2 Nov 18, 2023
0.8.0 Jul 19, 2023
0.4.0 Mar 29, 2023

#229 in Encoding

Download history 901/week @ 2023-12-23 2041/week @ 2023-12-30 2962/week @ 2024-01-06 2482/week @ 2024-01-13 3251/week @ 2024-01-20 2870/week @ 2024-01-27 2723/week @ 2024-02-03 2404/week @ 2024-02-10 1986/week @ 2024-02-17 3123/week @ 2024-02-24 4071/week @ 2024-03-02 2828/week @ 2024-03-09 3484/week @ 2024-03-16 2594/week @ 2024-03-23 4537/week @ 2024-03-30 3647/week @ 2024-04-06

14,816 downloads per month
Used in 2 crates

Apache-2.0

730KB
17K 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–15MB
~163K SLoC