io.vertx.kafka.client.common.tracing

## Class ConsumerTracer<S>

- java.lang.Object
- - io.vertx.kafka.client.common.tracing.ConsumerTracer<S>

-     public class ConsumerTracer<S>
      extends Object

  Tracer for Kafka consumer, wrapping the generic tracer.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `class` | `ConsumerTracer.StartedSpan`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static <S> ConsumerTracer` | `create(VertxTracer tracer, KafkaClientOptions opts)` Creates a ConsumerTracer, which provides an opinionated facade for using `VertxTracer` with a Kafka Consumer use case.
    `ConsumerTracer.StartedSpan` | `prepareMessageReceived(Context context, org.apache.kafka.clients.consumer.ConsumerRecord rec)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### create

          public static <S> ConsumerTracer create(VertxTracer tracer,
                                                  KafkaClientOptions opts)

      Creates a ConsumerTracer, which provides an opinionated facade for using `VertxTracer` with a Kafka Consumer use case. The method will return `null` if Tracing is not setup in Vert.x, or if `TracingPolicy.IGNORE` is used.
      Type Parameters:
        `S` - the type of spans that is going to be generated, depending on the tracing system (zipkin, opentracing ...)
      Parameters:
        `tracer` - the generic tracer object
        `opts` - Kafka client options
      Returns:
        a new instance of `ConsumerTracer`, or `null`

    - #### prepareMessageReceived

          public ConsumerTracer.StartedSpan prepareMessageReceived(Context context,
                                                                   org.apache.kafka.clients.consumer.ConsumerRecord rec)

Copyright © 2021 Eclipse. All rights reserved.