mirror of
https://github.com/lukaszraczylo/traefikoidc.git
synced 2026-10-15 04:18:03 +00:00
Multiple changes to improve performance and reduce complexity.
- Optimise the errors and recovery. - Deduplicate code in metadata cache. - Remove unused performance monitoring code. - Simplify session management and settings handling.
This commit is contained in:
+11
@@ -469,6 +469,17 @@ func (l *Logger) Errorf(format string, args ...any) {
|
||||
l.logError.Printf(format, args...)
|
||||
}
|
||||
|
||||
// newNoOpLogger creates a silent logger that doesn't output anything.
|
||||
// This is useful for internal components that need a logger instance
|
||||
// but should not produce any output by default.
|
||||
func newNoOpLogger() *Logger {
|
||||
return &Logger{
|
||||
logError: log.New(io.Discard, "", 0),
|
||||
logInfo: log.New(io.Discard, "", 0),
|
||||
logDebug: log.New(io.Discard, "", 0),
|
||||
}
|
||||
}
|
||||
|
||||
// handleError logs an error message using the provided logger and sends an HTTP error
|
||||
// response to the client with the specified message and status code.
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user