Documentation
¶
Index ¶
- func Debug(ctx context.Context, msgFormat string, args ...interface{})
- func Debuge(e pubsub.Event, msgFormat string, args ...interface{})
- func Debugf(msgFormat string, args ...interface{})
- func Debugw(keysAndValues []interface{}, msgFormat string, args ...interface{})
- func Error(ctx context.Context, msgFormat string, args ...interface{})
- func Errore(e pubsub.Event, msgFormat string, args ...interface{})
- func Errorf(msgFormat string, args ...interface{})
- func Errorw(keysAndValues []interface{}, msgFormat string, args ...interface{})
- func Fatal(ctx context.Context, msgFormat string, args ...interface{})
- func Fatale(e pubsub.Event, msgFormat string, args ...interface{})
- func Fatalf(msgFormat string, args ...interface{})
- func Fatalw(keysAndValues []interface{}, msgFormat string, args ...interface{})
- func Info(ctx context.Context, msgFormat string, args ...interface{})
- func Infoe(e pubsub.Event, msgFormat string, args ...interface{})
- func Infof(msgFormat string, args ...interface{})
- func Infow(keysAndValues []interface{}, msgFormat string, args ...interface{})
- func ReplaceGlobal(logger log.Logger)
- func Warn(ctx context.Context, msgFormat string, args ...interface{})
- func Warne(e pubsub.Event, msgFormat string, args ...interface{})
- func Warnf(msgFormat string, args ...interface{})
- func Warnw(keysAndValues []interface{}, msgFormat string, args ...interface{})
- type HttpRequestLog
- type LoggingContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReplaceGlobal ¶
ReplaceGlobal Register a logger instance as global
Types ¶
type HttpRequestLog ¶
type HttpRequestLog struct { LoggingContext Url string `json:"url"` Status int `json:"status"` ExecutionTime int64 `json:"execution_time"` RequestPattern string `json:"request_pattern,omitempty"` RequestPath string `json:"request_path"` Method string `json:"request_method"` Query string `json:"query,omitempty"` RequestId string `json:"request_id,omitempty"` CallerId string `json:"caller_id,omitempty"` ClientIp string `json:"client_ip,omitempty"` UserAgent string `json:"user_agent,omitempty"` }
type LoggingContext ¶
type LoggingContext struct { CorrelationId string `json:"request_id,omitempty"` UserId string `json:"jwt_subject,omitempty"` DeviceId string `json:"device_id,omitempty"` DeviceSessionId string `json:"device_session_id,omitempty"` TechnicalUsername string `json:"technical_username,omitempty"` }
func BuildLoggingContextFromEvent ¶
func BuildLoggingContextFromEvent(e *event.AbstractEvent) *LoggingContext
func BuildLoggingContextFromEventAttr ¶
func BuildLoggingContextFromEventAttr(attributes *event.Attributes) *LoggingContext
func BuildLoggingContextFromReqAttr ¶
func BuildLoggingContextFromReqAttr(requestAttributes *webContext.RequestAttributes) *LoggingContext
Click to show internal directories.
Click to hide internal directories.