initial import

This commit is contained in:
kevin
2020-07-26 17:09:05 +08:00
commit 7e3a369a8f
647 changed files with 54754 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
package tracespec
type SpanContext interface {
TraceId() string
SpanId() string
Visit(fn func(key, val string) bool)
}

View File

@@ -0,0 +1,10 @@
package tracespec
import "context"
type Trace interface {
SpanContext
Finish()
Fork(ctx context.Context, serviceName, operationName string) (context.Context, Trace)
Follow(ctx context.Context, serviceName, operationName string) (context.Context, Trace)
}

View File

@@ -0,0 +1,3 @@
package tracespec
const TracingKey = "X-Trace"