java.lang.Object
com.linecorp.armeria.common.util.AbstractUnwrappable<Service<T_I,T_O>>
com.linecorp.armeria.server.DecoratingService<I,O,I,O>
com.linecorp.armeria.server.SimpleDecoratingService<I,O>
com.linecorp.armeria.server.throttling.AbstractThrottlingService<I,O>
- All Implemented Interfaces:
Unwrappable
,Service<I,O>
- Direct Known Subclasses:
ThrottlingRpcService
,ThrottlingService
public abstract class AbstractThrottlingService<I extends Request,O extends Response> extends SimpleDecoratingService<I,O>
Decorates a
Service
to throttle incoming requests.-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractThrottlingService(Service<I,O> delegate, ThrottlingStrategy<I> strategy, Function<CompletionStage<? extends O>,O> responseConverter, ThrottlingAcceptHandler<I,O> acceptHandler, ThrottlingRejectHandler<I,O> rejectHandler)
Creates a new instance that decorates the specifiedService
. -
Method Summary
Modifier and Type Method Description O
serve(ServiceRequestContext ctx, I req)
Serves an incomingRequest
.Methods inherited from class com.linecorp.armeria.server.DecoratingService
serviceAdded, shouldCachePath
Methods inherited from class com.linecorp.armeria.common.util.AbstractUnwrappable
as, delegate, toString, unwrap
-
Constructor Details
-
AbstractThrottlingService
protected AbstractThrottlingService(Service<I,O> delegate, ThrottlingStrategy<I> strategy, Function<CompletionStage<? extends O>,O> responseConverter, ThrottlingAcceptHandler<I,O> acceptHandler, ThrottlingRejectHandler<I,O> rejectHandler)Creates a new instance that decorates the specifiedService
.
-
-
Method Details