Class KafkaStreamsMetrics
java.lang.Object
io.micrometer.core.instrument.binder.kafka.KafkaStreamsMetrics
- All Implemented Interfaces:
MeterBinder
,AutoCloseable
@Incubating(since="1.4.0")
@NonNullApi
@NonNullFields
public class KafkaStreamsMetrics
extends Object
Kafka Streams metrics binder. This should be closed on application shutdown to clean up
resources.
It is based on the Kafka client's metrics()
method returning a Metric
map.
Meter names have the following convention: kafka.(metric_group).(metric_name)
- Since:
- 1.4.0
- See Also:
-
Constructor Summary
ConstructorDescriptionKafkaStreamsMetrics
(org.apache.kafka.streams.KafkaStreams kafkaStreams) KafkaStreams
metrics binderKafkaStreamsMetrics
(org.apache.kafka.streams.KafkaStreams kafkaStreams, Iterable<Tag> tags) KafkaStreams
metrics binder -
Method Summary
-
Constructor Details
-
KafkaStreamsMetrics
KafkaStreams
metrics binder- Parameters:
kafkaStreams
- instance to be instrumentedtags
- additional tags
-
KafkaStreamsMetrics
public KafkaStreamsMetrics(org.apache.kafka.streams.KafkaStreams kafkaStreams) KafkaStreams
metrics binder- Parameters:
kafkaStreams
- instance to be instrumented
-
-
Method Details
-
bindTo
- Specified by:
bindTo
in interfaceMeterBinder
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-