grpchan icon indicating copy to clipboard operation
grpchan copied to clipboard

Support stats handler

Open devnev opened this issue 9 months ago • 1 comments

I'd like to use OpenTelemetry to track the calls made via grpchan. The otelgrpc package go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc has marked its interceptor-based implementations as deprecated, favouring the google.golang.org/grpc/stats.Handler API, but grpchan doesn't currently support this API. Could support for stats.Handler be added?

devnev avatar Feb 25 '25 05:02 devnev

Although I was thinking about server stats handler when I made the issue, the same request applies to client stats handler. In particular, because grpchan blocks context values from crossing from the client to the server, something like the otelgrpc client stats handler is needed to place trace values in the grpc metdata so that trace context is propagated across the grpchan call.

devnev avatar Feb 25 '25 11:02 devnev

#83

dragonsinth avatar Oct 29 '25 15:10 dragonsinth