Versions in this module Expand all Collapse all v0 v0.1.2 Sep 3, 2026 Changes in this version + func Close() v0.1.1 Aug 23, 2026 Changes in this version + const LevelDebug + const LevelError + const LevelFatal + const LevelInfo + const LevelWarn + const PanicPrefix + var DebugContext = func(ctx context.Context, args ...any) + var DebugfContext = func(ctx context.Context, format string, args ...any) + var ErrorContext = func(ctx context.Context, args ...any) + var ErrorfContext = func(ctx context.Context, format string, args ...any) + var FatalContext = func(ctx context.Context, args ...any) + var FatalfContext = func(ctx context.Context, format string, args ...any) + var InfoContext = func(ctx context.Context, args ...any) + var InfofContext = func(ctx context.Context, format string, args ...any) + var TracefContext = func(ctx context.Context, format string, args ...any) + var WarnContext = func(ctx context.Context, args ...any) + var WarnfContext = func(ctx context.Context, format string, args ...any) + func FatalfCtx(ctx context.Context, format string, args ...interface{}) + func IsTraceEnabled() bool + func PrintDebug(args ...any) + func PrintError(args ...any) + func PrintFatal(args ...any) + func PrintInfo(args ...any) + func PrintWarn(args ...any) + func SetLevel(level string) + func SetTraceEnabled(enabled bool) + func Tracef(format string, args ...any) + type Logger interface + Debug func(args ...any) + Debugf func(format string, args ...any) + Error func(args ...any) + Errorf func(format string, args ...any) + Fatal func(args ...any) + Fatalf func(format string, args ...any) + Info func(args ...any) + Infof func(format string, args ...any) + Warn func(args ...any) + Warnf func(format string, args ...any) + var ContextDefault Logger + var Default Logger v0.1.0 Aug 20, 2026 Changes in this version + const CallIDKey + const CampaignIDKey + const DefaultSensitiveFields + const DefaultTimezone + const GinCtxReqIDKey + const HeaderXReqID + const RequestIDKey + const TenantIDKey + const TraceIDKey + const UserIDKey + const XReqIDKey + var Lg *zap.Logger + func Debug(msg string, fields ...zap.Field) + func DebugCtx(ctx context.Context, msg string, fields ...zap.Field) + func Debugf(format string, args ...interface{}) + func DebugfCtx(ctx context.Context, format string, args ...interface{}) + func Error(msg string, fields ...zap.Field) + func ErrorCtx(ctx context.Context, msg string, fields ...zap.Field) + func ErrorWithRedactedFields(msg string, fields map[string]interface{}) + func Errorf(format string, args ...interface{}) + func ErrorfCtx(ctx context.Context, format string, args ...interface{}) + func Fatal(msg string, fields ...zap.Field) + func FatalCtx(ctx context.Context, msg string, fields ...zap.Field) + func Fatalf(format string, args ...interface{}) + func GenReqID() string + func GetDailyLogFilename(baseFilename string) string + func Info(msg string, fields ...zap.Field) + func InfoCtx(ctx context.Context, msg string, fields ...zap.Field) + func InfoWithRedactedFields(msg string, fields map[string]interface{}) + func Infof(format string, args ...interface{}) + func InfofCtx(ctx context.Context, format string, args ...interface{}) + func Init(config *LogConfig, mode string) (err error) + func InitTimezone(name string) + func IsSensitiveField(key string) bool + func LogDirFromFilename(filename string) string + func Panic(msg string, fields ...zap.Field) + func PanicCtx(ctx context.Context, msg string, fields ...zap.Field) + func Panicf(format string, args ...interface{}) + func PurgeExpiredLogFiles(logDir string, retentionDays int) (removed int, err error) + func RedactEmail(email string) string + func RedactField(key string, value interface{}) interface + func RedactFields(fields map[string]interface{}) map[string]interface + func RedactPhone(phone string) string + func RedactSIPURI(s string) string + func RedactString(s string) string + func RedactValue(data string) string + func RequestIDFromContext(ctx context.Context) string + func SafeGo(name string, fn func()) + func Sync() + func Warn(msg string, fields ...zap.Field) + func WarnCtx(ctx context.Context, msg string, fields ...zap.Field) + func Warnf(format string, args ...interface{}) + func WarnfCtx(ctx context.Context, format string, args ...interface{}) + func WithError(err error) zap.Field + func WithFields(fields map[string]interface{}) []zap.Field + func WithRequestID(ctx context.Context, reqID string) context.Context + func WrapCoreWithReqIDPrefix(inner zapcore.Core) zapcore.Core + func ZapReqID(ctx context.Context) zap.Field + func ZapReqIDString(reqID string) zap.Field + type LogConfig struct + Daily bool + Filename string + Level string + MaxAge int + MaxBackups int + MaxSize int + RetentionDays int + SensitiveFields string