Package com.linkedin.venice.router.stats
Class RouterHttpRequestStats
- java.lang.Object
-
- com.linkedin.venice.stats.AbstractVeniceStats
-
- com.linkedin.venice.stats.AbstractVeniceHttpStats
-
- com.linkedin.venice.router.stats.RouterHttpRequestStats
-
public class RouterHttpRequestStats extends AbstractVeniceHttpStats
-
-
Field Summary
-
Fields inherited from class com.linkedin.venice.stats.AbstractVeniceStats
DELIMITER
-
-
Constructor Summary
Constructors Constructor Description RouterHttpRequestStats(io.tehuti.metrics.MetricsRepository metricsRepository, java.lang.String storeName, RequestType requestType, ScatterGatherStats scatterGatherStats, boolean isKeyValueProfilingEnabled)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static boolean
hasInFlightRequests()
void
recordAllowedRetryRequest()
void
recordBadRequest()
void
recordBadRequestKeyCount(int keyCount)
void
recordCompressedResponseSize(double compressedResponseSize)
void
recordDecompressionTime(double decompressionTime)
void
recordDelayConstraintAbortedRetryRequest()
void
recordDisallowedRetryRequest()
void
recordErrorRetryAttemptTriggeredByPendingRequestCheck()
void
recordErrorRetryCount()
void
recordFanoutRequestCount(int count)
void
recordFindUnhealthyHostRequest()
void
recordHealthyRequest(java.lang.Double latency)
void
recordKeyNum(int keyNum)
void
recordKeySizeInByte(long keySize)
void
recordLatency(double latency)
void
recordMetaStoreShadowRead()
void
recordMultiGetFallback(int keyCount)
void
recordNoAvailableReplicaAbortedRetryRequest()
void
recordQuota(double quota)
void
recordReadQuotaUsage(int quotaUsage)
Record read quota usage based on healthy KPS.void
recordRequest()
We record this at the beginning of request handling, so we don't know the latency yet...void
recordRequestParsingLatency(double latency)
void
recordRequestRoutingLatency(double latency)
void
recordRequestSize(double requestSize)
void
recordRequestThrottledByRouterCapacity()
void
recordRequestUsage(int usage)
void
recordResponse()
void
recordResponseSize(double responseSize)
void
recordResponseWaitingTime(double waitingTime)
void
recordRetryDelay(double delay)
void
recordRetryRouteLimitAbortedRetryRequest()
void
recordSlowRouteAbortedRetryRequest()
void
recordTardyRequest(double latency)
void
recordThrottledRequest()
Once we stop reporting throttled requests inRouterExceptionAndTrackingUtils
, and we only report them inVeniceResponseAggregator
then we will always have a latency and we'll be able to remove this overload.void
recordThrottledRequest(double latency)
void
recordUnavailableReplicaStreamingRequest()
void
recordUnavailableRequest()
void
recordUnhealthyRequest()
void
recordUnhealthyRequest(double latency)
protected io.tehuti.metrics.Sensor
registerSensor(java.lang.String sensorName, io.tehuti.metrics.MeasurableStat... stats)
By default, this function will prepend the request type to the sensor name.-
Methods inherited from class com.linkedin.venice.stats.AbstractVeniceHttpStats
getFullMetricName, getRequestType, registerSensor, registerSensor, registerSensorWithDetailedPercentiles
-
Methods inherited from class com.linkedin.venice.stats.AbstractVeniceStats
avgAndMax, avgAndTotal, getMetricsRepository, getName, getSensorFullName, getSensorFullName, isTotalStats, minAndMax, registerOnlyTotalRate, registerOnlyTotalSensor, registerPerStoreAndTotalSensor, registerSensor, registerSensorAttributeGauge, registerSensorIfAbsent, registerSensorIfAbsent, registerSensorIfAbsent, registerSensorWithAggregate, registerSensorWithAggregate, unregisterAllSensors
-
-
-
-
Constructor Detail
-
RouterHttpRequestStats
public RouterHttpRequestStats(io.tehuti.metrics.MetricsRepository metricsRepository, java.lang.String storeName, RequestType requestType, ScatterGatherStats scatterGatherStats, boolean isKeyValueProfilingEnabled)
-
-
Method Detail
-
recordRequest
public void recordRequest()
We record this at the beginning of request handling, so we don't know the latency yet... All specific types of requests also have their latencies logged at the same time.
-
recordHealthyRequest
public void recordHealthyRequest(java.lang.Double latency)
-
recordUnhealthyRequest
public void recordUnhealthyRequest()
-
recordUnavailableReplicaStreamingRequest
public void recordUnavailableReplicaStreamingRequest()
-
recordUnhealthyRequest
public void recordUnhealthyRequest(double latency)
-
recordReadQuotaUsage
public void recordReadQuotaUsage(int quotaUsage)
Record read quota usage based on healthy KPS.- Parameters:
quotaUsage
-
-
recordTardyRequest
public void recordTardyRequest(double latency)
-
recordThrottledRequest
public void recordThrottledRequest(double latency)
-
recordThrottledRequest
public void recordThrottledRequest()
Once we stop reporting throttled requests inRouterExceptionAndTrackingUtils
, and we only report them inVeniceResponseAggregator
then we will always have a latency and we'll be able to remove this overload. TODO: Remove this overload after fixing the above.
-
recordErrorRetryCount
public void recordErrorRetryCount()
-
recordBadRequest
public void recordBadRequest()
-
recordBadRequestKeyCount
public void recordBadRequestKeyCount(int keyCount)
-
recordRequestThrottledByRouterCapacity
public void recordRequestThrottledByRouterCapacity()
-
recordFanoutRequestCount
public void recordFanoutRequestCount(int count)
-
recordLatency
public void recordLatency(double latency)
-
recordResponseWaitingTime
public void recordResponseWaitingTime(double waitingTime)
-
recordRequestSize
public void recordRequestSize(double requestSize)
-
recordCompressedResponseSize
public void recordCompressedResponseSize(double compressedResponseSize)
-
recordResponseSize
public void recordResponseSize(double responseSize)
-
recordDecompressionTime
public void recordDecompressionTime(double decompressionTime)
-
recordQuota
public void recordQuota(double quota)
-
recordFindUnhealthyHostRequest
public void recordFindUnhealthyHostRequest()
-
recordKeyNum
public void recordKeyNum(int keyNum)
-
recordRequestUsage
public void recordRequestUsage(int usage)
-
recordMultiGetFallback
public void recordMultiGetFallback(int keyCount)
-
recordRequestParsingLatency
public void recordRequestParsingLatency(double latency)
-
recordRequestRoutingLatency
public void recordRequestRoutingLatency(double latency)
-
recordUnavailableRequest
public void recordUnavailableRequest()
-
recordDelayConstraintAbortedRetryRequest
public void recordDelayConstraintAbortedRetryRequest()
-
recordSlowRouteAbortedRetryRequest
public void recordSlowRouteAbortedRetryRequest()
-
recordRetryRouteLimitAbortedRetryRequest
public void recordRetryRouteLimitAbortedRetryRequest()
-
recordNoAvailableReplicaAbortedRetryRequest
public void recordNoAvailableReplicaAbortedRetryRequest()
-
recordKeySizeInByte
public void recordKeySizeInByte(long keySize)
-
recordResponse
public void recordResponse()
-
recordAllowedRetryRequest
public void recordAllowedRetryRequest()
-
recordDisallowedRetryRequest
public void recordDisallowedRetryRequest()
-
recordErrorRetryAttemptTriggeredByPendingRequestCheck
public void recordErrorRetryAttemptTriggeredByPendingRequestCheck()
-
recordRetryDelay
public void recordRetryDelay(double delay)
-
recordMetaStoreShadowRead
public void recordMetaStoreShadowRead()
-
registerSensor
protected io.tehuti.metrics.Sensor registerSensor(java.lang.String sensorName, io.tehuti.metrics.MeasurableStat... stats)
Description copied from class:AbstractVeniceHttpStats
By default, this function will prepend the request type to the sensor name.- Overrides:
registerSensor
in classAbstractVeniceHttpStats
-
hasInFlightRequests
public static boolean hasInFlightRequests()
-
-