Prepare verified laboratory 7 implementation and evidence

This commit is contained in:
rey
2026-11-17 17:32:06 +03:00
parent 20afc2c790
commit eb1b5c7b84
677 changed files with 208256 additions and 64 deletions
+14
View File
@@ -0,0 +1,14 @@
package model
import "context"
type traceKey struct{}
type TraceCarrier struct{ Traceparent, Tracestate string }
func WithTrace(ctx context.Context, parent, state string) context.Context {
return context.WithValue(ctx, traceKey{}, TraceCarrier{parent, state})
}
func TraceFrom(ctx context.Context) TraceCarrier {
v, _ := ctx.Value(traceKey{}).(TraceCarrier)
return v
}