Package com.linkedin.davinci.stats
Class KafkaConsumerServiceStats
java.lang.Object
com.linkedin.venice.stats.AbstractVeniceStats
com.linkedin.davinci.stats.KafkaConsumerServiceStats
This class provides the stats for Kafka consumer service per region or per store.
Stats inside this class can either:
(1) Total only: The stat indicate total number of all the stores on this host per region.
(2) Total and Per store only: The stat is registered for each store on this host.
-
Field Summary
Fields inherited from class com.linkedin.venice.stats.AbstractVeniceStats
DELIMITER -
Constructor Summary
ConstructorsConstructorDescriptionKafkaConsumerServiceStats(io.tehuti.metrics.MetricsRepository metricsRepository, String storeName, LongSupplier getMaxElapsedTimeSinceLastPollInConsumerPool, KafkaConsumerServiceStats totalStats, Time time, String clusterName) -
Method Summary
Modifier and TypeMethodDescriptionvoidrecordAvgPartitionsPerConsumer(int count) voidrecordByteSizePerPoll(double count) Joint API — records to both Tehuti (Min, Max) and OTel (MIN_MAX_COUNT_SUM).voidrecordConsumerIdleTime(double time) Joint API — records to both Tehuti (Max) and OTel (MIN_MAX_COUNT_SUM).voidrecordConsumerRecordsProducingToWriterBufferLatency(double latency) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM).voidrecordDelegateSubscribeLatency(double value) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) with SUBSCRIBE dimension.voidrecordDetectedDeletedTopicNum(int count) Joint API — records to both Tehuti (Total) and OTel (COUNTER).voidJoint API — records to both Tehuti (Total) and OTel (COUNTER).voidrecordMaxPartitionsPerConsumer(int count) voidrecordMinPartitionsPerConsumer(int count) voidrecordNonZeroPollResultNum(int count) Joint API — records to both Tehuti (LongAdderRateGauge) and OTel (ASYNC_COUNTER_FOR_HIGH_PERF_CASES).voidrecordPartitionAssignmentForOtel(int partitionCount) Records a single per-consumer partition count to the OTel partition assignment histogram.voidJoint API — records to both Tehuti (OccurrenceRate) and OTel (COUNTER).voidrecordPollRequestLatency(double latency) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) for poll time, plus poll count.voidrecordPollResultNum(int count) Joint API — records to both Tehuti (Avg, Min) and OTel (MIN_MAX_COUNT_SUM).voidrecordSubscribedPartitionsNum(int count) voidrecordUpdateCurrentAssignmentLatency(double value) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) with UPDATE_ASSIGNMENT dimension.Methods inherited from class com.linkedin.venice.stats.AbstractVeniceStats
avgAndMax, avgAndTotal, getMetricFullName, getMetricsRepository, getName, getSensorFullName, getSensorFullName, isTotalStats, minAndMax, registerOnlyTotalRate, registerOnlyTotalSensor, registerPerStoreAndTotal, registerPerStoreAndTotalSensor, registerSensor, registerSensor, registerSensor, registerSensor, registerSensorAttributeGauge, registerSensorIfAbsent, registerSensorIfAbsent, registerSensorIfAbsent, registerSensorWithAggregate, registerSensorWithAggregate, unregisterAllSensors
-
Constructor Details
-
KafkaConsumerServiceStats
public KafkaConsumerServiceStats(io.tehuti.metrics.MetricsRepository metricsRepository, String storeName, LongSupplier getMaxElapsedTimeSinceLastPollInConsumerPool, KafkaConsumerServiceStats totalStats, Time time, String clusterName)
-
-
Method Details
-
recordPollRequestLatency
public void recordPollRequestLatency(double latency) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) for poll time, plus poll count. -
recordPollResultNum
public void recordPollResultNum(int count) Joint API — records to both Tehuti (Avg, Min) and OTel (MIN_MAX_COUNT_SUM). -
recordNonZeroPollResultNum
public void recordNonZeroPollResultNum(int count) Joint API — records to both Tehuti (LongAdderRateGauge) and OTel (ASYNC_COUNTER_FOR_HIGH_PERF_CASES). -
recordConsumerRecordsProducingToWriterBufferLatency
public void recordConsumerRecordsProducingToWriterBufferLatency(double latency) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM). -
recordPollError
public void recordPollError()Joint API — records to both Tehuti (OccurrenceRate) and OTel (COUNTER). -
recordDetectedDeletedTopicNum
public void recordDetectedDeletedTopicNum(int count) Joint API — records to both Tehuti (Total) and OTel (COUNTER). -
recordDetectedNoRunningIngestionTopicPartitionNum
public void recordDetectedNoRunningIngestionTopicPartitionNum(int count) Joint API — records to both Tehuti (Total) and OTel (COUNTER). -
recordDelegateSubscribeLatency
public void recordDelegateSubscribeLatency(double value) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) with SUBSCRIBE dimension. -
recordUpdateCurrentAssignmentLatency
public void recordUpdateCurrentAssignmentLatency(double value) Joint API — records to both Tehuti (Avg, Max) and OTel (HISTOGRAM) with UPDATE_ASSIGNMENT dimension. -
recordMinPartitionsPerConsumer
public void recordMinPartitionsPerConsumer(int count) -
recordMaxPartitionsPerConsumer
public void recordMaxPartitionsPerConsumer(int count) -
recordAvgPartitionsPerConsumer
public void recordAvgPartitionsPerConsumer(int count) -
recordByteSizePerPoll
public void recordByteSizePerPoll(double count) Joint API — records to both Tehuti (Min, Max) and OTel (MIN_MAX_COUNT_SUM). -
recordConsumerIdleTime
public void recordConsumerIdleTime(double time) Joint API — records to both Tehuti (Max) and OTel (MIN_MAX_COUNT_SUM). -
recordSubscribedPartitionsNum
public void recordSubscribedPartitionsNum(int count) -
recordPartitionAssignmentForOtel
public void recordPartitionAssignmentForOtel(int partitionCount) Records a single per-consumer partition count to the OTel partition assignment histogram. Called for each consumer in the pool fromKafkaConsumerService.recordPartitionsPerConsumerSensor(). Tehuti keeps 4 pre-computed gauge values; OTel records raw per-consumer values to a single MIN_MAX_COUNT_SUM histogram.
-