jetty-runtime icon indicating copy to clipboard operation
jetty-runtime copied to clipboard

Track the Jetty request span in Cloud Trace

Open meltsufin opened this issue 8 years ago • 4 comments

The span of the request while being processed by Jetty should be reported to Cloud Trace by adding a span to the trace ID found in the x-cloud-trace-context HTTP header. It should be possible to optionally enable/disable this feature.

meltsufin avatar Jul 24 '17 13:07 meltsufin

Perhaps use Open Census for this in order to enable tracing for gRPC calls as well: https://github.com/census-instrumentation/opencensus-java/tree/master/exporters/trace_stackdriver#quickstart

meltsufin avatar Sep 05 '17 20:09 meltsufin

Note that for other reasons we are working on adding a new listener to the next jetty 9.4 release that will make it much simpler to track all phases of a request/response life cycle - request line, headers complete, body complete, commit response, response complete.

gregw avatar Sep 06 '17 00:09 gregw

Thanks for the heads of up Greg! It sounds like it would be good place to plug in our tracing.

meltsufin avatar Sep 06 '17 13:09 meltsufin

Note that HttpChannel.Listeners were added in 9.4.8, which should be ideal for this task.

gregw avatar Jan 12 '18 09:01 gregw