mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-06 04:09:40 -06:00
add test spans
This commit is contained in:
@@ -11,8 +11,8 @@ var propagator = propagation.NewCompositeTextMapPropagator(
|
||||
propagation.TraceContext{},
|
||||
)
|
||||
|
||||
// Trace unpacks the request context looking for an existing trace id.
|
||||
func Trace(next http.Handler) http.Handler {
|
||||
// TraceContext unpacks the request context looking for an existing trace id.
|
||||
func TraceContext(next http.Handler) http.Handler {
|
||||
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
ctx := propagator.Extract(r.Context(), propagation.HeaderCarrier(r.Header))
|
||||
propagator.Inject(ctx, propagation.HeaderCarrier(r.Header))
|
||||
|
||||
Reference in New Issue
Block a user