Documentation ¶
Index ¶
- func Exists(haystack map[string]interface{}, needle string) bool
- func ExpandNested(key string, value interface{}, dest map[string]interface{})
- func GetLogrusCaller() *stack.FrameInfo
- func RequestToMap(req *http.Request) map[string]interface{}
- func ToFields(items map[string]string) logrus.Fields
- type LogRecord
- type Number
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExpandNested ¶
func GetLogrusCaller ¶
Returns the file, function and line number of the function that called logrus
func RequestToMap ¶
Given a *http.Request return a map with detailed information about the request
Types ¶
type LogRecord ¶
type LogRecord struct { Context map[string]interface{} `json:"context,omitempty"` Category string `json:"category,omitempty"` AppName string `json:"appname"` HostName string `json:"hostname"` LogLevel string `json:"logLevel"` FileName string `json:"filename"` FuncName string `json:"funcName"` LineNo int `json:"lineno"` Message string `json:"message"` Timestamp Number `json:"timestamp"` CID string `json:"cid,omitempty"` PID int `json:"pid,omitempty"` TID string `json:"tid,omitempty"` ExcType string `json:"excType,omitempty"` ExcText string `json:"excText,omitempty"` ExcValue string `json:"excValue,omitempty"` }
func (*LogRecord) FromFields ¶
func (LogRecord) MarshalEasyJSON ¶
MarshalEasyJSON supports easyjson.Marshaler interface
func (LogRecord) MarshalJSON ¶
MarshalJSON supports json.Marshaler interface
func (*LogRecord) UnmarshalEasyJSON ¶
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*LogRecord) UnmarshalJSON ¶
UnmarshalJSON supports json.Unmarshaler interface
Click to show internal directories.
Click to hide internal directories.