Exemplo n.º 1
0
        public static ClientSpan Create(string tracerId, string traceId, string parentSpanId, string spanId, string opName, IDictionary <string, string> bags = null)
        {
            var theSpan = new ClientSpan();

            Set(theSpan, tracerId, traceId, parentSpanId, spanId, opName, bags);
            return(theSpan);
        }
Exemplo n.º 2
0
        public static ClientSpan Set(ClientSpan clientSpan, string tracerId, string traceId, string parentSpanId, string spanId, string opName, IDictionary <string, string> bags = null)
        {
            if (bags != null)
            {
                clientSpan.Bags = bags;
            }

            //todo validate
            clientSpan.TracerId     = tracerId;
            clientSpan.TraceId      = traceId;
            clientSpan.SpanId       = spanId;
            clientSpan.ParentSpanId = parentSpanId;
            clientSpan.OpName       = opName;

            return(clientSpan);
        }