Class: AWSCDK::SNS::ThrottlePolicy

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
sns/throttle_policy.rb

Overview

Options for customising AWS SNS HTTP/S delivery throttling.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(max_receives_per_second: nil) ⇒ ThrottlePolicy

Returns a new instance of ThrottlePolicy.

Parameters:

  • max_receives_per_second (Numeric, nil) (defaults to: nil)

    The maximum number of deliveries per second, per subscription.



8
9
10
11
# File 'sns/throttle_policy.rb', line 8

def initialize(max_receives_per_second: nil)
  @max_receives_per_second = max_receives_per_second
  Jsii::Type.check_type(@max_receives_per_second, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "maxReceivesPerSecond") unless @max_receives_per_second.nil?
end

Instance Attribute Details

#max_receives_per_secondNumeric? (readonly)

Note:

Default: - no throttling

The maximum number of deliveries per second, per subscription.

Returns:

  • (Numeric, nil)


17
18
19
# File 'sns/throttle_policy.rb', line 17

def max_receives_per_second
  @max_receives_per_second
end

Class Method Details

.jsii_propertiesObject



19
20
21
22
23
# File 'sns/throttle_policy.rb', line 19

def self.jsii_properties
  {
    :max_receives_per_second => "maxReceivesPerSecond",
  }
end

Instance Method Details

#to_jsiiObject



25
26
27
28
29
30
31
# File 'sns/throttle_policy.rb', line 25

def to_jsii
  result = {}
  result.merge!({
    "maxReceivesPerSecond" => @max_receives_per_second,
  })
  result.compact
end