Synopsis
Currently Authula has a default logger set to use slog by default but developers want the ability to inject their own custom logger such as: zap, zerolog, logrus and others.
This ticket therefore suggests refactoring the logger config within the main config to allow developers in Library Mode to be able to provide a custom logger via a Logger interface to keep things simple and maintainable.
Implementation
For example:
interface Logger {
Debug(msg string, args ...any)
Info(msg string, args ...any)
Warn(msg string, args ...any)
Error(msg string, args ...any)
}
Synopsis
Currently Authula has a default logger set to use
slogby default but developers want the ability to inject their own custom logger such as: zap, zerolog, logrus and others.This ticket therefore suggests refactoring the logger config within the main config to allow developers in Library Mode to be able to provide a custom logger via a
Loggerinterface to keep things simple and maintainable.Implementation
For example: