pub struct RequestLogConfig {
pub exclude_paths: Vec<String>,
pub log_duration: bool,
}Expand description
请求日志中间件配置
Fields§
§exclude_paths: Vec<String>不记录日志的路径列表(如 “/api/health”) 注意不含prefix前缀
log_duration: bool是否记录请求耗时
Trait Implementations§
Source§impl Clone for RequestLogConfig
impl Clone for RequestLogConfig
Source§fn clone(&self) -> RequestLogConfig
fn clone(&self) -> RequestLogConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 RequestLogConfig
impl Debug for RequestLogConfig
Source§impl Default for RequestLogConfig
impl Default for RequestLogConfig
Source§impl<'de> Deserialize<'de> for RequestLogConfig
impl<'de> Deserialize<'de> for RequestLogConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RequestLogConfig
impl RefUnwindSafe for RequestLogConfig
impl Send for RequestLogConfig
impl Sync for RequestLogConfig
impl Unpin for RequestLogConfig
impl UnsafeUnpin for RequestLogConfig
impl UnwindSafe for RequestLogConfig
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