package
0.40.0
Repository: https://github.com/radius-project/radius.git
Documentation: pkg.go.dev

# Functions

FromContextOrDiscard returns a logger with trace and span IDs populated from the context if they exist.
NewLogger creates a new logger with zap logger implementation, with the given name and logging options, and returns a function to flush the logs before the server exits.
This function creates a new resource object with the given service name, hostname and version.
Unwrap attempts to extract the underlying zap.Logger from a logr.Logger, returning nil if it fails.
WrapLogContext adds key-value pairs to the context's logger for logging purposes.

# Constants

Radius uses the Zapr: https://github.com/go-logr/zapr which implements a logr interface for a zap log sink.
Logger Profiles which determines the logger configuration.
HttpCorrelationId represents the x-forwarded-for HTTP header.
HttpUserAgent represents the user-agent HTTP header.
HttpXForwardedFor represents the x-forwarded-for HTTP header.
LevelDebug should be used for messages that should not be shown in production.
LevelInfo is the default.
LogFieldCorrelationID represents the X-Correlation-ID that may be present in the incoming request.
LogFieldHostName represents the current hostname.
LogFieldResourceID represents the Radius Resource ID.
LogFieldServiceName represents the name of the service generating the log entry.
LogFieldSpanId represents the spanId retrieved from traceparent header of current HTTP request.
LogFieldTargetResourceID represents the resource ID of a non-Radius resource.
LogFieldTraceId represents the traceId retrieved from traceparent header of the current HTTP request.
LogFieldVersion represents the version of service.
No description provided by the author
Logger Profiles which determines the logger configuration.
Logger Profiles which determines the logger configuration.
Env variable that determines the log level.
Env variable that determines the logger config presets.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

LoggingOptions represents the logger.