grpcdc/status
library
Classes
-
TraceContext
-
One in-flight span's context.
-
Tracer
-
Observer for homegrown tracing (beta) (W3C traceparent propagation).
Functions
-
formatTraceparent(String traceId, String spanId, bool sampled)
→ String
-
-
newTraceContext(String kind, String method)
→ TraceContext?
-
Start a root span context (client workflows). Pair with traceEnd.
-
parentOf(TraceContext? ctx)
→ ({bool sampled, String spanId, String traceId})?
-
View a span context as a traceparent parent.
-
parseTraceparent(String? value)
→ ({bool sampled, String spanId, String traceId})?
-
-
setTraceFilter(String patterns)
→ void
-
Restrict traced methods: ';'-separated paths, a trailing
'' means prefix match ('/echo.Echo/'). Empty = trace all.
-
setTracer(Tracer? tracer)
→ void
-
Register the global span observer (null disables tracing).
Dormant until set: sampling/export are the app's problem.
-
traceEnd(String kind, String method, TraceContext? ctx, String status)
→ void
-
-
traceStart(String kind, String method, ({bool sampled, String spanId, String traceId})? parent)
→ TraceContext?
-
Exceptions / Errors
-
EndOfStreamError
-
Thrown at end of a receiving stream (call completed OK).
-
StatusException
-
A gRPC status (code + message) carried as an exception.