final class RateLimitMarketPlaceOn extends RateLimitBaseService
Modifier and Type | Field and Description |
---|---|
private com.google.common.eventbus.EventBus |
eventbus |
private static org.slf4j.Logger |
log |
Constructor and Description |
---|
RateLimitMarketPlaceOn(RateLimitConfiguration config,
javax.inject.Provider<RateLimitRepository> repo,
int limit,
long timeToLiveInMillis,
com.google.common.eventbus.EventBus eventbus) |
Modifier and Type | Method and Description |
---|---|
RateLimit |
consume(java.lang.String id) |
private void |
notifyLimitExceded(RateLimit rateLimit) |
private void |
notifyThresholdExceded(RateLimit rateLimit) |
get, getConfig
private static final org.slf4j.Logger log
private final com.google.common.eventbus.EventBus eventbus
public RateLimitMarketPlaceOn(RateLimitConfiguration config, javax.inject.Provider<RateLimitRepository> repo, int limit, long timeToLiveInMillis, com.google.common.eventbus.EventBus eventbus)
public RateLimit consume(java.lang.String id)
consume
in interface RateLimitService
consume
in class RateLimitBaseService
id
- either a Shop GUID or a OAuth1 TokenID :(private void notifyLimitExceded(RateLimit rateLimit)
private void notifyThresholdExceded(RateLimit rateLimit)