quarkusio/quarkus

OpenTelemetry: Respect provided TracingPolicy in VertxTracer implementations

Open

#25,417 创建于 2022年5月6日

在 GitHub 查看
 (5 评论) (0 反应) (0 负责人)Java (12,967 star) (2,464 fork)batch import
area/tracinggood first issuekind/enhancement

描述

Description

When using the quarkus-opentelemetry extension, there currently seems to be no direct way to switch off certain kinds of instrumentation. For example, the Vert.x event bus instrumentation might produce traces that are not needed in certain applications and just produce noise there.

Reading the Vert.x OpenTelemetry documentation, the assumption would be, that the solution here is to just set the TracingPolicy.IGNORE policy on the Vert.x event bus DeliveryOptions.

But this doesn't work with the Quarkus VertxTracer implementations. There, the TracingPolicy parameter is getting ignored (in contrast to the Vert.x OpenTelemetryTracer implementation).

Another example would be HTTP server/client instrumention, where also the TracingPolicy can be set in the client/server options. Being able to use TracingPolicy.IGNORE there would for example make it easier to migrate applications already having a (manual) HTTP request instrumentation. (Letting the HttpInstrumenterVertxTracer traces be discarded by means of a custom Sampler implementation looks like an inferior workaround.)

Implementation ideas

Skip request processing in the Quarkus VertxTracer implementations for requests with TracingPolicy.IGNORE (as done in the Vert.x OpenTelemetryTracer).

贡献者指南

OpenTelemetry: Respect provided TracingPolicy in VertxTracer implementations · quarkusio/quarkus#25417 | Good First Issue