Exemplo n.º 1
0
        protected internal SpanContext ExtractTraceContext(HttpContext context)
        {
            var request = context.Request;

            return(Propagation.Extract(request.Headers, (d, k) =>
            {
                d.TryGetValue(k, out var result);
                return result;
            }));
        }
        protected internal ISpanContext ExtractTraceContext(HttpContext context)
        {
            var request = context.Request;
            try
            {
                return Propagation.Extract(request.Headers, headerGetter);
            }
            catch (SpanContextParseException)
            {
                // Ignore
            }

            return null;
        }
Exemplo n.º 3
0
        protected internal ISpanContext ExtractTraceContext(HttpContext context)
        {
            var request = context.Request;

            try
            {
                return(Propagation.Extract(request.Headers, (d, k) =>
                {
                    d.TryGetValue(k, out StringValues result);
                    return result;
                }));
            }
            catch (SpanContextParseException)
            {
                // Ignore
            }

            return(null);
        }