@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.240Z") @Stability(value=Stable) public interface ThrottleSettings extends software.amazon.jsii.JsiiSerializable
Example:
LambdaIntegration integration;
RestApi api = new RestApi(this, "hello-api");
Resource v1 = api.root.addResource("v1");
Resource echo = v1.addResource("echo");
Method echoMethod = echo.addMethod("GET", integration, MethodOptions.builder().apiKeyRequired(true).build());
UsagePlan plan = api.addUsagePlan("UsagePlan", UsagePlanProps.builder()
.name("Easy")
.throttle(ThrottleSettings.builder()
.rateLimit(10)
.burstLimit(2)
.build())
.build());
IApiKey key = api.addApiKey("ApiKey");
plan.addApiKey(key);
| Modifier and Type | Interface and Description |
|---|---|
static class |
ThrottleSettings.Builder
A builder for
ThrottleSettings |
static class |
ThrottleSettings.Jsii$Proxy
An implementation for
ThrottleSettings |
| Modifier and Type | Method and Description |
|---|---|
static ThrottleSettings.Builder |
builder() |
default Number |
getBurstLimit()
The maximum API request rate limit over a time ranging from one to a few seconds.
|
default Number |
getRateLimit()
The API request steady-state rate limit (average requests per second over an extended period of time).
|
@Stability(value=Stable) @Nullable default Number getBurstLimit()
Default: none
@Stability(value=Stable) @Nullable default Number getRateLimit()
Default: none
@Stability(value=Stable) static ThrottleSettings.Builder builder()
ThrottleSettings.Builder of ThrottleSettingsCopyright © 2022. All rights reserved.