interface ThrottlePolicy
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.SNS.ThrottlePolicy |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awssns#ThrottlePolicy |
Java | software.amazon.awscdk.services.sns.ThrottlePolicy |
Python | aws_cdk.aws_sns.ThrottlePolicy |
TypeScript (source) | aws-cdk-lib » aws_sns » ThrottlePolicy |
Options for customising AWS SNS HTTP/S delivery throttling.
Example
const myTopic = new sns.Topic(this, 'MyTopic');
myTopic.addSubscription(
new subscriptions.UrlSubscription(
'https://foobar.com/',
{
deliveryPolicy: {
healthyRetryPolicy: {
minDelayTarget: Duration.seconds(5),
maxDelayTarget: Duration.seconds(10),
numRetries: 6,
backoffFunction: sns.BackoffFunction.EXPONENTIAL,
},
throttlePolicy: {
maxReceivesPerSecond: 10,
},
requestPolicy: {
headerContentType: 'application/json',
},
},
},
),
);
Properties
Name | Type | Description |
---|---|---|
max | number | The maximum number of deliveries per second, per subscription. |
maxReceivesPerSecond?
Type:
number
(optional, default: no throttling)
The maximum number of deliveries per second, per subscription.