pub struct LoggingConfig {
pub level: String,
pub file: Option<String>,
}Expand description
Logging configuration.
Controls log verbosity and output destinations.
§Log Levels
From most to least verbose:
trace- Very detailed debug informationdebug- Debug information useful for developmentinfo- General informational messages (default)warn- Warning messages for potentially problematic situationserror- Error messages for failures
§Example
[logging]
level = "info"
file = "logs/velora.log"Fields§
§level: StringLog level (trace, debug, info, warn, error) Env: VELORA_LOGGING_LEVEL
file: Option<String>Optional log file path Env: VELORA_LOGGING_FILE
If not specified, logs are written to stdout only.
Trait Implementations§
Source§impl Clone for LoggingConfig
impl Clone for LoggingConfig
Source§impl Debug for LoggingConfig
impl Debug for LoggingConfig
Source§impl Default for LoggingConfig
impl Default for LoggingConfig
Source§impl<'de> Deserialize<'de> for LoggingConfig
impl<'de> Deserialize<'de> for LoggingConfig
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 LoggingConfig
impl RefUnwindSafe for LoggingConfig
impl Send for LoggingConfig
impl Sync for LoggingConfig
impl Unpin for LoggingConfig
impl UnsafeUnpin for LoggingConfig
impl UnwindSafe for LoggingConfig
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