Skip to content

Add file rotation for logger #61

Description

@Fullstop000

Currently, we use a simple file to store all log messages:

wickdb/src/logger.rs

Lines 54 to 58 in 15c37cc

let file = storage
.create(generate_filename(db_path, FileType::InfoLog, 0).as_str())
.unwrap();
slog_async::Async::new(FileBasedDrain::new(file))
.build()

This could be a bad design as the log messages growing. Adding a file rotation by implementing a slog Drain might be a good solution.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P: LowLow priorityenhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions