Structured Persistent Logger
structured_persistent_logger
is a Rust crate providing a structured logging solution that is compatible with the standard log
crate. It features persistent logging capabilities, allowing for the retention and structured formatting of log records.
Features
- Integration with the standard
log
crate. - Structured logging with JSON formatting.
- Persistent logging capabilities across application lifecycle.
- Thread-safe logging with support for multi-threaded environments.
Installation
Add structured_persistent_logger
to your Cargo.toml
:
[]
= "0.1.0"
= "0.4.0"
Usage
To use structured_persistent_logger
, initialize it at the start of your application:
use StructuredPersistentLogger;
Adding Persistent Logs
You can add persistent logs that will be included in every log message:
use add_persistent_logs;
use json;
Configuration
The logger can be configured to adjust its behavior, such as setting log levels or customizing the format of log entries.
Contributing
We welcome contributions to structured_persistent_logger
! Please feel free to submit pull requests or open issues to improve the library.
License
This crate is licensed under MIT license.