Skip to main content

GetLogFields

Gets a map of all known logKeys set on the context. logKeys are special and should be used in case, context fields are to be added to the log lines.

def GetLogFields(
ctx: context.Context
) - > map[string]interface{}

Gets a map of all known logKeys set on the context. LogKeys are special and should be used in case context fields are to be added to the log lines.

Parameters

NameTypeDescription
ctxcontext.ContextThe context from which to retrieve the log fields.

Returns

TypeDescription
map[string]interface{}A map containing all known log keys and their corresponding values from the context.