Documentation ¶
Index ¶
- func JaegerTraceProvider(url, deploymentEnvironmentKey string) (*sdktrace.TracerProvider, func(context.Context), error)
- func LogErrorWithTrace(span trace.Span, logger *log.Entry, msg string, keyValues ...KeyValueForLog)
- func LogSuccessWithTrace(span trace.Span, logger *log.Entry, msg string, keyValues ...KeyValueForLog)
- type KeyValueForLog
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func JaegerTraceProvider ¶
func JaegerTraceProvider(url, deploymentEnvironmentKey string) (*sdktrace.TracerProvider, func(context.Context), error)
JaegerTraceProvider returns a new instance of sdktrace.TracerProvider configured with Jaeger exporter, along with its shutdown function. The provided URL is used as the collector endpoint for sending traces.
func LogErrorWithTrace ¶
LogErrorWithTrace logs an error message modifies the passed in trace span. It sets the status of the span to an error, records the error, and logs the error message using the provided logger.
func LogSuccessWithTrace ¶
func LogSuccessWithTrace(span trace.Span, logger *log.Entry, msg string, keyValues ...KeyValueForLog)
LogSuccessWithTrace logs a success message with the passed in logger and sets the passed-in span's status to OK
Types ¶
type KeyValueForLog ¶
KeyValueForLog is a struct that holds a key and value for logging purposes
Click to show internal directories.
Click to hide internal directories.