Class VeniceAdaptiveIngestionThrottler
java.lang.Object
com.linkedin.venice.throttle.EventThrottler
com.linkedin.davinci.kafka.consumer.VeniceAdaptiveIngestionThrottler
- All Implemented Interfaces:
VeniceRateLimiter
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.linkedin.venice.throttle.VeniceRateLimiter
VeniceRateLimiter.RateLimiterType
-
Field Summary
Fields inherited from class com.linkedin.venice.throttle.EventThrottler
BLOCK_STRATEGY, REJECT_STRATEGY
-
Constructor Summary
ConstructorDescriptionVeniceAdaptiveIngestionThrottler
(int signalIdleThreshold, long quotaPerSecond, long timeWindow, String throttlerName) -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
maybeThrottle
(double eventsSeen) Sleeps if necessary to slow down the caller.void
registerBoosterSignal
(BooleanSupplier supplier) void
registerLimiterSignal
(BooleanSupplier supplier) Methods inherited from class com.linkedin.venice.throttle.EventThrottler
getConfiguredMaxRatePerSecond, getMaxRatePerSecond, getQuota, getRateConfig, getTime, isCheckQuotaBeforeRecording, setQuota, toString, tryAcquirePermit
-
Constructor Details
-
VeniceAdaptiveIngestionThrottler
public VeniceAdaptiveIngestionThrottler(int signalIdleThreshold, long quotaPerSecond, long timeWindow, String throttlerName)
-
-
Method Details
-
maybeThrottle
public void maybeThrottle(double eventsSeen) Description copied from class:EventThrottler
Sleeps if necessary to slow down the caller.- Overrides:
maybeThrottle
in classEventThrottler
- Parameters:
eventsSeen
- Number of events seen since last invocation. Basis for determining whether its necessary to sleep.
-
registerLimiterSignal
-
registerBoosterSignal
-
checkSignalAndAdjustThrottler
public void checkSignalAndAdjustThrottler()
-