|
|
@ -27,8 +27,8 @@ func (a *loggerAppliance) SetLogger(in Logger) { |
|
|
|
a.Logger = in |
|
|
|
a.Logger = in |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
func (a *loggerAppliance) GetLogger() Logger { |
|
|
|
func (a *loggerAppliance) Log(level Level, keyvals ...interface{}) error { |
|
|
|
return a.Logger |
|
|
|
return a.Logger.Log(level, keyvals...) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// SetLogger should be called before any other log call.
|
|
|
|
// SetLogger should be called before any other log call.
|
|
|
@ -39,7 +39,7 @@ func SetLogger(logger Logger) { |
|
|
|
|
|
|
|
|
|
|
|
// GetLogger returns global logger appliance as logger in current process.
|
|
|
|
// GetLogger returns global logger appliance as logger in current process.
|
|
|
|
func GetLogger() Logger { |
|
|
|
func GetLogger() Logger { |
|
|
|
return global.GetLogger() |
|
|
|
return global |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Log Print log by level and keyvals.
|
|
|
|
// Log Print log by level and keyvals.
|
|
|
|