miden_note_transport_node/lib.rs
1//! # Miden Transport Layer Client Library
2//!
3//! Implementation of the Miden Transport Layer node for private notes.
4//!
5//! The implementation is focused on performance and privacy.
6//! Only (optionally-encrypted) notes are stored.
7//!
8//! Features include,
9//! - sending and receiving notes;
10//! - streaming of notes;
11//! - note persistence using proven-databases and respective maintenance;
12//! - metrics and traces, exported through the OpenTelemetry framework for monitoring.
13//!
14//! ## Database
15//! Notes are stored in a database, implementing the
16//! [`Database`](`crate::database::DatabaseBackend`). A SQLite-based implementation is provided.
17//!
18//! ### Maintenance
19//! A periodic task [`DatabaseMaintenance`](`crate::database::DatabaseMaintenance`) takes care of
20//! maintaining the database (cleaning up older notes).
21//!
22//! ## Telemetry
23//! Metrics and traces to monitor the node state are provided.
24//! While metrics provide insights into general requests stats, traces can provide insights into
25//! specific requests.
26//! Metrics and traces can be exported following using the [OpenTelemetry](https://opentelemetry.io) framework.
27
28#![deny(missing_docs)]
29
30/// Database
31pub mod database;
32/// Error management
33pub mod error;
34/// Tracing, metrics export configuration
35pub mod logging;
36/// Metrics data structures
37pub mod metrics;
38/// Main node implementation
39pub mod node;
40/// Testing functions
41///
42/// Available during tests or when the `testing` feature is enabled.
43#[cfg(any(test, feature = "testing"))]
44pub mod test_utils;
45/// Types used
46pub mod types;
47
48pub use error::{Error, Result};
49pub use node::grpc::GrpcServer;
50pub use node::{Node, NodeConfig};