Documentation
¶
Index ¶
- Constants
- func InjectTraceID(ctx opentracing.SpanContext, header http.Header)
- func Middleware(ctx *fiber.Ctx) error
- func SetIfCtxErr(span opentracing.Span, ctx context.Context)
- func SetIfErr(span opentracing.Span, err error)
- func StartDBSpanWithParent(parent opentracing.SpanContext, ...) opentracing.Span
- func StartSpan(operationName, method, path string) opentracing.Span
- func StartSpanWithParent(parent opentracing.SpanContext, operationName, method, path string) opentracing.Span
Constants ¶
View Source
const ( // error keys KeyErrorMessage = "err_msg" KeyContextErrorMessage = "ctx_err_msg" )
Variables ¶
This section is empty.
Functions ¶
func InjectTraceID ¶
func Middleware ¶
func Middleware(ctx *fiber.Ctx) error
func SetIfCtxErr ¶
func StartDBSpanWithParent ¶
func StartDBSpanWithParent(parent opentracing.SpanContext, operationName, dbInstance, dbType, dbStatement string) opentracing.Span
StartDBSpanWithParent - start a DB operation span
func StartSpan ¶
func StartSpan(operationName, method, path string) opentracing.Span
StartSpan will start a new span with no parent span.
func StartSpanWithParent ¶
func StartSpanWithParent(parent opentracing.SpanContext, operationName, method, path string) opentracing.Span
StartSpanWithParent will start a new span with a parent span. example:
span:= StartSpanWithParent(c.Get("tracing-context"),
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.