withTraceContext method

Channel withTraceContext(
  1. TraceContext? ctx
)

A Channel view sharing this endpoint whose outbound spans are parented to ctx. Explicit call metadata still wins.

Implementation

Channel withTraceContext(TraceContext? ctx) {
  final ch = Channel.fromEndpoint(endpoint);
  ch._traceContext = ctx;
  return ch;
}