All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.muserver.RateLimitSelector Maven / Gradle / Ivy

The newest version!
package io.muserver;

/**
 * A function that controls how rate limits are applied. See {@link MuServerBuilder#withRateLimiter(RateLimitSelector)}
 * for usage details.
 */
public interface RateLimitSelector {

    /**
     * Selects a rate limit bucket based on the current request.
     * @param request An incoming request
     * @return A rate limit object, or null to not apply rate limiting to this request.
     */
    RateLimit select(MuRequest request);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy