lxy 0.1.1

A convenient async http and RPC framework in Rust
Documentation
//! OpenTelemetry integration for Lxy.
//!
//! This module provides out-of-box OpenTelemetry support for tracing and metrics,
//! allowing applications to export telemetry data to OpenTelemetry-compatible backends
//! like Jaeger, Zipkin, or the OpenTelemetry Collector.
//!
//! # Features
//!
//! - Automatic HTTP request tracing with spans
//! - Integration with the `tracing` ecosystem
//! - OTLP exporter support (gRPC and HTTP)
//! - Configurable via TOML configuration
//!
//! # Configuration
//!
//! Enable OpenTelemetry by adding the following to your `app.toml`:
//!
//! ```toml
//! [otel]
//! enabled = true
//! service_name = "my-service"
//! endpoint = "http://localhost:4317"
//! protocol = "grpc"  # or "http"
//! processor = "batch"  # or "simple"
//! ```

pub mod builder;
pub mod config;
pub mod tracing_layer;

pub use builder::{create_otel_layer, init_tracer_provider};
pub use config::OtelConfig;
pub(crate) use tracing_layer::with_timing;
pub use tracing_layer::{TracingLayer, TracingService};