pub struct EnhancedLoggingMiddleware { /* private fields */ }
Expand description
Enhanced logging middleware with structured logging and request tracing
Implementations§
Source§impl EnhancedLoggingMiddleware
impl EnhancedLoggingMiddleware
Sourcepub fn with_config(config: LoggingConfig) -> Self
pub fn with_config(config: LoggingConfig) -> Self
Create with custom configuration
Sourcepub fn structured(self, enabled: bool) -> Self
pub fn structured(self, enabled: bool) -> Self
Builder pattern: Enable structured JSON logging
Sourcepub fn log_request_body(self, enabled: bool) -> Self
pub fn log_request_body(self, enabled: bool) -> Self
Builder pattern: Enable request body logging
Sourcepub fn log_response_body(self, enabled: bool) -> Self
pub fn log_response_body(self, enabled: bool) -> Self
Builder pattern: Enable response body logging
Sourcepub fn correlation_ids(self, enabled: bool) -> Self
pub fn correlation_ids(self, enabled: bool) -> Self
Builder pattern: Enable correlation ID tracking
Sourcepub fn slow_request_threshold(self, threshold: Duration) -> Self
pub fn slow_request_threshold(self, threshold: Duration) -> Self
Builder pattern: Set slow request threshold
Sourcepub fn log_request_headers(self, enabled: bool) -> Self
pub fn log_request_headers(self, enabled: bool) -> Self
Builder pattern: Enable request header logging
Source§impl EnhancedLoggingMiddleware
Convenience builder for common logging configurations
impl EnhancedLoggingMiddleware
Convenience builder for common logging configurations
Sourcepub fn development() -> Self
pub fn development() -> Self
Development configuration: verbose logging, correlation IDs, no body logging
Sourcepub fn production() -> Self
pub fn production() -> Self
Production configuration: structured logging, correlation IDs, minimal verbosity
Trait Implementations§
Source§impl Clone for EnhancedLoggingMiddleware
impl Clone for EnhancedLoggingMiddleware
Source§fn clone(&self) -> EnhancedLoggingMiddleware
fn clone(&self) -> EnhancedLoggingMiddleware
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for EnhancedLoggingMiddleware
impl Debug for EnhancedLoggingMiddleware
Source§impl Default for EnhancedLoggingMiddleware
impl Default for EnhancedLoggingMiddleware
Source§impl Middleware for EnhancedLoggingMiddleware
impl Middleware for EnhancedLoggingMiddleware
Source§fn handle(&self, request: ElifRequest, next: Next) -> NextFuture<'static>
fn handle(&self, request: ElifRequest, next: Next) -> NextFuture<'static>
Handle the request and call the next middleware in the chain
Auto Trait Implementations§
impl Freeze for EnhancedLoggingMiddleware
impl RefUnwindSafe for EnhancedLoggingMiddleware
impl Send for EnhancedLoggingMiddleware
impl Sync for EnhancedLoggingMiddleware
impl Unpin for EnhancedLoggingMiddleware
impl UnwindSafe for EnhancedLoggingMiddleware
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more