1#![forbid(unsafe_code)]
23#![warn(missing_docs)]
24
25pub mod backplane;
26pub mod cache;
27pub mod circuit;
28pub mod distributed;
29pub mod distributed_lock;
30pub mod entry;
31pub mod error;
32pub mod events;
33pub mod factory;
34pub mod locking;
35pub mod maybe;
36pub mod memory;
37pub mod observability;
38pub mod options;
39pub mod plugins;
40pub mod recovery;
41pub mod registry;
42pub mod serializers;
43pub mod tags;
44pub mod time;
45
46#[cfg(feature = "opentelemetry")]
47pub mod otel;
48
49#[cfg(feature = "redis")]
50pub mod redis_backend;
51
52pub use backplane::{Backplane, BackplaneAction, BackplaneMessage, InProcessBackplane};
53pub use cache::{Cache, CacheBuilder};
54pub use circuit::CircuitBreaker;
55pub use distributed::{
56 DistributedCache, DistributedEntry, DistributedSerializer, InMemoryDistributedCache,
57 JsonSerializer,
58};
59pub use distributed_lock::{DistributedLocker, InMemoryDistributedLocker};
60pub use error::{Error, FactoryError, Result};
61pub use events::{CacheEvent, CircuitComponent, Events};
62pub use factory::{FactoryContext, FactoryProduct, ModifiedBuilder};
63pub use maybe::MaybeValue;
64pub use options::{EagerThreshold, EntryOptions, KeyModifierMode, Priority, RemoveByTagBehavior};
65pub use plugins::{Plugin, PluginHost};
66pub use recovery::{
67 AutoRecoveryService, RecoveryAction, RecoveryConfig, RecoveryExecutor, RecoveryItem,
68};
69pub use registry::{CacheRegistry, DefaultEntryOptionsProvider};
70pub use tags::Tag;
71pub use time::{Clock, ManualClock, SystemClock, Timeout, Timestamp};
72
73#[cfg(feature = "messagepack")]
74pub use serializers::MessagePackSerializer;
75
76#[cfg(feature = "postcard")]
77pub use serializers::PostcardSerializer;
78
79#[cfg(feature = "metrics")]
80pub use observability::MetricsPlugin;
81
82#[cfg(feature = "opentelemetry")]
83pub use otel::{OtelGuard, init_otlp};
84
85#[cfg(feature = "redis")]
86pub use redis_backend::{RedisBackplane, RedisDistributedCache, RedisDistributedLocker};