#id #generate #snowflake-like

fastid

Snowflake-like ID generating in Rust

8 releases

0.3.3 Nov 23, 2023
0.3.2 Nov 23, 2023
0.2.2 Feb 23, 2021
0.2.0 Jan 31, 2021
0.1.1 Jun 3, 2020

#60 in #id

MIT license

9KB
169 lines

FastID-rs

Crates.io Docs.rs Crates.io Crates.io

Snowflake-like ID generating in Rust

Usage

use fastid::FastIdWorker;

let mut worker = FastIdWorker::new(1);

let id = worker.next_id();

println!("{:#064b}", id);
println!("{}", id);

License

The MIT License

More info see LICENSE

Dependencies

~125KB