Package io.datarouter.ratelimiter
Class BaseTallyCacheRateLimiter
java.lang.Object
io.datarouter.ratelimiter.BaseRateLimiter
io.datarouter.ratelimiter.BaseCacheRateLimiter
io.datarouter.ratelimiter.BaseTallyCacheRateLimiter
public class BaseTallyCacheRateLimiter extends BaseCacheRateLimiter
-
Constructor Summary
Constructors Constructor Description BaseTallyCacheRateLimiter(BaseTallyDao tallyDao, CacheRateLimiterConfig config) -
Method Summary
Modifier and Type Method Description protected java.lang.Longincrement(java.lang.String key)protected java.util.Map<java.lang.String,java.lang.Long>readCounts(java.util.List<java.lang.String> keys)Methods inherited from class io.datarouter.ratelimiter.BaseCacheRateLimiter
getBucketTimeInterval, getConfig, getTimeStr, internalAllowMethods inherited from class io.datarouter.ratelimiter.BaseRateLimiter
allowed, allowed, allowedForIp, allowedForIp, getName, peek
-
Constructor Details
-
Method Details
-
increment
protected java.lang.Long increment(java.lang.String key)- Specified by:
incrementin classBaseCacheRateLimiter
-
readCounts
protected java.util.Map<java.lang.String,java.lang.Long> readCounts(java.util.List<java.lang.String> keys)- Specified by:
readCountsin classBaseCacheRateLimiter
-