Hi
I would like to add child field for logging. I want ta add a field from context.currenctUser?.code but I cant implement. How to handle this?
I use dbAuth and all queries or mutations needs authentication.
Hi
I would like to add child field for logging. I want ta add a field from context.currenctUser?.code but I cant implement. How to handle this?
I use dbAuth and all queries or mutations needs authentication.
I followed this function, probably its not allowed to add additional field from context
/**
const childLogger = logger.child({
name: ‘graphql-server’,
})
childLogger.level = level
const includeOperationName = loggerConfig?.options?.operationName
const includeRequestId = loggerConfig?.options?.requestId
const includeUserAgent = loggerConfig?.options?.userAgent
const includeQuery = loggerConfig?.options?.query
const excludeOperations = loggerConfig.options?.excludeOperations