Class: AWSCDK::CodeDeploy::CanaryTrafficRoutingConfig
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::CodeDeploy::CanaryTrafficRoutingConfig
- Defined in:
- code_deploy/canary_traffic_routing_config.rb
Overview
Represents the configuration specific to canary traffic shifting.
Instance Attribute Summary collapse
-
#canary_interval ⇒ Numeric
readonly
The number of minutes between the first and second traffic shifts of a
TimeBasedCanarydeployment. -
#canary_percentage ⇒ Numeric
readonly
The percentage of traffic to shift in the first increment of a
TimeBasedCanarydeployment.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(canary_interval:, canary_percentage:) ⇒ CanaryTrafficRoutingConfig
constructor
A new instance of CanaryTrafficRoutingConfig.
- #to_jsii ⇒ Object
Constructor Details
#initialize(canary_interval:, canary_percentage:) ⇒ CanaryTrafficRoutingConfig
Returns a new instance of CanaryTrafficRoutingConfig.
9 10 11 12 13 14 |
# File 'code_deploy/canary_traffic_routing_config.rb', line 9 def initialize(canary_interval:, canary_percentage:) @canary_interval = canary_interval Jsii::Type.check_type(@canary_interval, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "canaryInterval") @canary_percentage = canary_percentage Jsii::Type.check_type(@canary_percentage, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "canaryPercentage") end |
Instance Attribute Details
#canary_interval ⇒ Numeric (readonly)
The number of minutes between the first and second traffic shifts of a TimeBasedCanary deployment.
19 20 21 |
# File 'code_deploy/canary_traffic_routing_config.rb', line 19 def canary_interval @canary_interval end |
#canary_percentage ⇒ Numeric (readonly)
The percentage of traffic to shift in the first increment of a TimeBasedCanary deployment.
23 24 25 |
# File 'code_deploy/canary_traffic_routing_config.rb', line 23 def canary_percentage @canary_percentage end |
Class Method Details
.jsii_properties ⇒ Object
25 26 27 28 29 30 |
# File 'code_deploy/canary_traffic_routing_config.rb', line 25 def self.jsii_properties { :canary_interval => "canaryInterval", :canary_percentage => "canaryPercentage", } end |
Instance Method Details
#to_jsii ⇒ Object
32 33 34 35 36 37 38 39 |
# File 'code_deploy/canary_traffic_routing_config.rb', line 32 def to_jsii result = {} result.merge!({ "canaryInterval" => @canary_interval, "canaryPercentage" => @canary_percentage, }) result.compact end |