Skip to main content

distkit/
lib.rs

1#![doc = include_str!("../docs/lib.md")]
2#![cfg_attr(docsrs, feature(doc_cfg), warn(rustdoc::broken_intra_doc_links))]
3#![deny(missing_docs)]
4#![forbid(unsafe_code)]
5
6mod common;
7pub use common::*;
8mod comparator;
9pub use comparator::*;
10#[cfg(feature = "counter")]
11pub mod counter;
12
13#[cfg(feature = "instance-aware-counter")]
14pub mod icounter;
15
16/// Rate limiting via the [`trypema`](https://docs.rs/trypema) crate.
17///
18/// This module re-exports all public types from `trypema`, providing
19/// sliding-window rate limiting with local, Redis-backed, and hybrid
20/// providers. Enable the `trypema` feature to use this module.
21#[cfg(feature = "trypema")]
22#[cfg_attr(docsrs, doc(cfg(feature = "trypema")))]
23pub mod trypema;
24
25mod error;
26pub use error::*;
27
28#[cfg(all(feature = "counter", feature = "instance-aware-counter"))]
29#[doc(hidden)]
30pub mod __doctest_helpers;