Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // Obsolete Logger instance for global debug-level logging. Retained for backward compatibility. // Deprecated: Use GlobalLoggers. Debug *log.Logger // Obsolete Logger instance for global info-level logging. Retained for backward compatibility. // Deprecated: Use GlobalLoggers. Info *log.Logger // Obsolete Logger instance for global warn-level logging. Retained for backward compatibility. // Deprecated: Use GlobalLoggers. Warning *log.Logger // Obsolete Logger instance for global error-level logging. Retained for backward compatibility. // Deprecated: Use GlobalLoggers. Error *log.Logger )
Global package level loggers - these are preserved for backward compatibility, but in a future version they will be replaced by ldlog.Loggers. Output sent to these loggers does not have an environment name prefix, and is filtered by the logLevel/LOG_LEVEL parameter rather than by envLogLevel/ENV_LOG_LEVEL.
var GlobalLoggers ldlog.Loggers
Global logging object for Relay messages that are not tied to a specific environment. Use level-specific output methods such as Info/Infof, Warn/Warnf, tc.
Output sent here does not have an environment name prefix, and is filtered by the logLevel/LOG_LEVEL parameter rather than by envLogLevel/ENV_LOG_LEVEL.
The obsolete variables logging.Debug, logging.Info, etc. will still work, and will respect the log level configuration in terms of filtering, but will not include the level name in the output.
Functions ¶
func InitLogging ¶
func InitLogging( debugHandle io.Writer, infoHandle io.Writer, warningHandle io.Writer, errorHandle io.Writer)
InitLogging sets the destination streams for each logging level.
func InitLoggingWithLevel ¶
InitLoggingWithLevel sets up the default logger configuration based on a minimum log level. This is the preferred method rather than InitLogging.
func MakeLoggers ¶
MakeLoggers returns a ldlog.Loggers instance that uses the previously configured log writers, with an optional category description that will be prepended to messages.
Types ¶
This section is empty.