MCPcopy Index your code
hub / github.com/foxcpp/maddy / Msg

Method Msg

framework/log/log.go:102–106  ·  view source on GitHub ↗

Msg writes an event log message in a machine-readable format (currently JSON). name: msg\t{"key":"value","key2":"value2"} Key-value pairs are built from fields slice which should contain key strings followed by corresponding values. That is, for example, []interface{"key", "value", "key2", "valu

(msg string, fields ...interface{})

Source from the content-addressed store, hash-verified

100// Additionally, time.Time is written as a string in ISO 8601 format.
101// time.Duration follows fmt.Stringer rule above.
102func (l *Logger) Msg(msg string, fields ...interface{}) {
103 m := make(map[string]interface{}, len(fields)/2)
104 fieldsToMap(fields, m)
105 l.log(false, l.formatMsg(msg, m))
106}
107
108// Error writes an event log message in a machine-readable format (currently
109// JSON) containing information about the error. If err does have a Fields

Callers 15

moduleMainFunction · 0.80
moduleReloadFunction · 0.80
eventHandlerMethod · 0.80
abortMethod · 0.80
startDeliveryMethod · 0.80
RcptMethod · 0.80
LogoutMethod · 0.80
DataMethod · 0.80
LMTPDataMethod · 0.80
submissionPrepareMethod · 0.80
ConfigureMethod · 0.80
wrapClientErrMethod · 0.80

Calls 3

logMethod · 0.95
formatMsgMethod · 0.95
fieldsToMapFunction · 0.85

Tested by

no test coverage detected