-
-
Notifications
You must be signed in to change notification settings - Fork 392
Description
Feature Request
Is your feature request related to a problem? Please describe.
When using tracing-appender for rolling file logs, the rotation strategy (e.g., daily) defaults to UTC time, causing mismatches in log filenames with local dates in non-UTC timezones (e.g., Asia/Shanghai at UTC+8). Additionally, there's no built-in support for log compression (e.g., gzip), leading to rapid disk space consumption in high-volume logging scenarios.
Describe the solution you'd like
Add configurable timezone support for rolling (e.g., via chrono-tz integration for local or custom timezones like Tz::Asia__Shanghai) and optional compression formats (e.g., gzip on rotation). This could draw inspiration from or partially integrate features from the logroller crate, which already handles these seamlessly while maintaining compatibility with tracing subscribers.
Describe alternatives you've considered
Switching to third-party crates like logroller (for timezone and compression) or tracing-appender-plus (for local time support), but these introduce additional dependencies and potential API inconsistencies. Native enhancements would simplify adoption without forking or migrating.