Interface VertxTracer<I,O>

All Known Implementing Classes:
OpenTracingTracer, ZipkinTracer

public interface VertxTracer<I,O>
The tracer SPI used by Vert.x components to report activities.
Author:
Julien Viet
  • Field Details

  • Method Details

    • receiveRequest

      default <R> I receiveRequest(Context context, SpanKind kind, TracingPolicy policy, R request, String operation, Iterable<Map.Entry<String,String>> headers, TagExtractor<R> tagExtractor)
      Signal a request has been received and will be processed.
      Parameters:
      context - the context data attached to the request
      kind - the span kind
      policy - the policy to apply
      request - the request object
      operation - the request operation
      headers - a read-only view of the request headers
      tagExtractor - the request tag extractor
      Returns:
      the request trace
    • sendResponse

      default <R> void sendResponse(Context context, R response, I payload, Throwable failure, TagExtractor<R> tagExtractor)
      Signal the response is sent.
      Parameters:
      context - the context data attached to the request
      response - the response sent
      payload - the payload returned by receiveRequest(Context, SpanKind, TracingPolicy, R, String, Iterable, TagExtractor)
      failure - the failure when not null
      tagExtractor - the response tag extractor
    • sendRequest

      default <R> O sendRequest(Context context, SpanKind kind, TracingPolicy policy, R request, String operation, BiConsumer<String,String> headers, TagExtractor<R> tagExtractor)
      Signal a request is sent.

      When the method returns null, no propagation happens and the client shall not call receiveResponse(Context, R, O, Throwable, TagExtractor).

      Parameters:
      context - the context data attached to the request
      kind - the span kind
      policy - the policy to apply
      request - the request object
      operation - the request operation
      headers - a write only-view of the request headers
      tagExtractor - the request tag extractor
      Returns:
      the request trace
    • receiveResponse

      default <R> void receiveResponse(Context context, R response, O payload, Throwable failure, TagExtractor<R> tagExtractor)
      Signal a response has been received.
      Parameters:
      context - the context data attached to the request
      response - the response sent
      payload - the payload returned by sendRequest(Context, SpanKind, TracingPolicy, R, String, BiConsumer, TagExtractor)
      failure - the failure when not null
      tagExtractor - the response tag extractor
    • close

      default void close()
      Close the tracer.