Index
All Classes and Interfaces|All Packages
A
- Annotation-based (class handlers) - Search tag in class dev.relism.flash.ext.limiter.LimiterExtension
- Section
B
- Bucket - Class in dev.relism.flash.ext.limiter
-
Pre-allocated per-key rate limit state.
- Bucket() - Constructor for class dev.relism.flash.ext.limiter.Bucket
- BucketStore - Class in dev.relism.flash.ext.limiter
-
Thread-safe store of pre-allocated
Bucketinstances keyed by partition key. - BucketStore() - Constructor for class dev.relism.flash.ext.limiter.BucketStore
C
- check(Bucket, LimitConfig, long[]) - Method in interface dev.relism.flash.ext.limiter.RateLimitStrategy
-
Checks whether this request is within the limit and updates the bucket atomically.
- check(Bucket, LimitConfig, long[]) - Method in class dev.relism.flash.ext.limiter.strategy.FixedWindowStrategy
- check(Bucket, LimitConfig, long[]) - Method in class dev.relism.flash.ext.limiter.strategy.SlidingWindowStrategy
- check(Bucket, LimitConfig, long[]) - Method in class dev.relism.flash.ext.limiter.strategy.TokenBucketStrategy
- configure(FlashRegistrar<?>, FlashContext) - Method in class dev.relism.flash.ext.limiter.LimiterExtension
- create() - Method in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Creates a fresh, stateless
RateLimitStrategyinstance for this algorithm.
D
- dev.relism.flash.ext.limiter - package dev.relism.flash.ext.limiter
- dev.relism.flash.ext.limiter.strategy - package dev.relism.flash.ext.limiter.strategy
E
- equals(Object) - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Indicates whether some other object is "equal to" this one.
F
- FIXED_WINDOW - Enum constant in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Fixed-window counter: resets to zero at each clock-aligned window boundary.
- FixedWindowStrategy - Class in dev.relism.flash.ext.limiter.strategy
-
Fixed-window rate limit: allows up to
LimitConfig.limit()requests per window ofLimitConfig.windowMs()milliseconds. - FixedWindowStrategy() - Constructor for class dev.relism.flash.ext.limiter.strategy.FixedWindowStrategy
G
- get(String) - Method in class dev.relism.flash.ext.limiter.BucketStore
-
Returns the bucket for
key, creating one if absent. - Guard - Class in dev.relism.flash.ext.limiter
-
Manual rate-limit guard for lambda routes.
H
- hashCode() - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Returns a hash code value for this object.
I
- Implementation - Search tag in class dev.relism.flash.ext.limiter.strategy.FixedWindowStrategy
- Section
- Implementation - Search tag in class dev.relism.flash.ext.limiter.strategy.TokenBucketStrategy
- Section
K
- key() - Element in annotation interface dev.relism.flash.ext.limiter.Limit
-
Name of the resolver registered via
LimiterConfig.registerResolver(java.lang.String, dev.relism.flash.ext.limiter.KeyResolver). - KeyResolver - Interface in dev.relism.flash.ext.limiter
-
Extracts a partition key from an incoming request.
L
- Lambda routes (via Guard) - Search tag in class dev.relism.flash.ext.limiter.LimiterExtension
- Section
- limit() - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Returns the value of the
limitrecord component. - limit(String, int, long, TimeUnit) - Method in class dev.relism.flash.ext.limiter.Guard
-
Returns a
Middlewarethat enforces the given rate limit usingLimitStrategy.FIXED_WINDOW. - limit(String, int, long, TimeUnit, LimitStrategy) - Method in class dev.relism.flash.ext.limiter.Guard
-
Returns a
Middlewarethat enforces the given rate limit with the specified strategy. - Limit - Annotation Interface in dev.relism.flash.ext.limiter
-
Applies a rate limit to a class-based
RequestHandler. - LimitConfig - Record Class in dev.relism.flash.ext.limiter
-
Immutable configuration snapshot for a single rate-limit rule.
- LimitConfig(int, long, RateLimitStrategy) - Constructor for record class dev.relism.flash.ext.limiter.LimitConfig
-
Creates an instance of a
LimitConfigrecord class. - LimiterConfig - Class in dev.relism.flash.ext.limiter
-
Extension configuration: holds the named
KeyResolverregistry. - LimiterConfig() - Constructor for class dev.relism.flash.ext.limiter.LimiterConfig
- LimiterExtension - Class in dev.relism.flash.ext.limiter
-
Rate-limiting extension for Flash.
- LimiterExtension() - Constructor for class dev.relism.flash.ext.limiter.LimiterExtension
-
Installs with default config (only the built-in
"ip"resolver). - LimiterExtension(LimiterConfig) - Constructor for class dev.relism.flash.ext.limiter.LimiterExtension
-
Installs with a custom
LimiterConfig(custom resolvers, etc.). - LimitStrategy - Enum Class in dev.relism.flash.ext.limiter
-
Enumeration of built-in rate-limit algorithms.
R
- RateLimitStrategy - Interface in dev.relism.flash.ext.limiter
-
Contract for a rate-limit algorithm.
- registerResolver(String, KeyResolver) - Method in class dev.relism.flash.ext.limiter.LimiterConfig
-
Registers (or replaces) a named key resolver.
- requests() - Element in annotation interface dev.relism.flash.ext.limiter.Limit
-
Maximum number of requests allowed per
Limit.window(). - resolve(Request) - Method in interface dev.relism.flash.ext.limiter.KeyResolver
S
- SLIDING_WINDOW - Enum constant in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Sliding-window counter: interpolates between the previous window's count and the current window's count weighted by how far into the current window we are.
- SlidingWindowStrategy - Class in dev.relism.flash.ext.limiter.strategy
-
Sliding-window counter rate limit: approximates a true sliding window by interpolating between the previous fixed window's count and the current window's count.
- SlidingWindowStrategy() - Constructor for class dev.relism.flash.ext.limiter.strategy.SlidingWindowStrategy
- slot0 - Variable in class dev.relism.flash.ext.limiter.Bucket
- slot1 - Variable in class dev.relism.flash.ext.limiter.Bucket
- Slot layout - Search tag in class dev.relism.flash.ext.limiter.strategy.SlidingWindowStrategy
- Section
- strategy() - Element in annotation interface dev.relism.flash.ext.limiter.Limit
-
Rate-limit algorithm.
- strategy() - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Returns the value of the
strategyrecord component.
T
- TOKEN_BUCKET - Enum constant in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Token-bucket: tokens refill continuously.
- TokenBucketStrategy - Class in dev.relism.flash.ext.limiter.strategy
-
Token-bucket rate limit: tokens refill continuously at a rate of
limit / windowMstokens per millisecond, up to a maximum oflimittokens. - TokenBucketStrategy() - Constructor for class dev.relism.flash.ext.limiter.strategy.TokenBucketStrategy
- toString() - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Returns a string representation of this record class.
V
- valueOf(String) - Static method in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Returns the enum constant of this class with the specified name.
- values() - Static method in enum class dev.relism.flash.ext.limiter.LimitStrategy
-
Returns an array containing the constants of this enum class, in the order they are declared.
W
- window() - Element in annotation interface dev.relism.flash.ext.limiter.Limit
-
Window duration in
Limit.windowUnit()units. - windowMs() - Method in record class dev.relism.flash.ext.limiter.LimitConfig
-
Returns the value of the
windowMsrecord component. - windowUnit() - Element in annotation interface dev.relism.flash.ext.limiter.Limit
-
Unit for
Limit.window().
All Classes and Interfaces|All Packages