Class: AWSCDK::CodeDeploy::TimeBasedLinearTrafficRouting
- Inherits:
-
TrafficRouting
- Object
- TrafficRouting
- AWSCDK::CodeDeploy::TimeBasedLinearTrafficRouting
- Defined in:
- code_deploy/time_based_linear_traffic_routing.rb
Overview
Define a traffic routing config of type 'TimeBasedLinear'.
Class Method Summary collapse
Instance Method Summary collapse
-
#bind(_scope) ⇒ AWSCDK::CodeDeploy::TrafficRoutingConfig
Return a TrafficRoutingConfig of type
TimeBasedLinear. -
#initialize(props) ⇒ TimeBasedLinearTrafficRouting
constructor
A new instance of TimeBasedLinearTrafficRouting.
-
#interval ⇒ AWSCDK::Duration
The amount of time between additional traffic shifts.
-
#percentage ⇒ Numeric
The percentage to increase traffic on each traffic shift.
Constructor Details
#initialize(props) ⇒ TimeBasedLinearTrafficRouting
Returns a new instance of TimeBasedLinearTrafficRouting.
9 10 11 12 13 |
# File 'code_deploy/time_based_linear_traffic_routing.rb', line 9 def initialize(props) props = props.is_a?(Hash) ? ::AWSCDK::CodeDeploy::TimeBasedLinearTrafficRoutingProps.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY29kZWRlcGxveS5UaW1lQmFzZWRMaW5lYXJUcmFmZmljUm91dGluZ1Byb3BzIn0=")), "props") Jsii::Object.instance_method(:initialize).bind(self).call(props) end |
Class Method Details
.jsii_overridable_methods ⇒ Object
15 16 17 18 19 20 21 |
# File 'code_deploy/time_based_linear_traffic_routing.rb', line 15 def self.jsii_overridable_methods { :interval => { kind: :property, name: "interval", is_optional: false }, :percentage => { kind: :property, name: "percentage", is_optional: false }, :bind => { kind: :method, name: "bind", is_optional: false }, } end |
Instance Method Details
#bind(_scope) ⇒ AWSCDK::CodeDeploy::TrafficRoutingConfig
Return a TrafficRoutingConfig of type TimeBasedLinear.
41 42 43 44 |
# File 'code_deploy/time_based_linear_traffic_routing.rb', line 41 def bind(_scope) Jsii::Type.check_type(_scope, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJjb25zdHJ1Y3RzLkNvbnN0cnVjdCJ9")), "_scope") jsii_call_method("bind", [_scope]) end |
#interval ⇒ AWSCDK::Duration
The amount of time between additional traffic shifts.
26 27 28 |
# File 'code_deploy/time_based_linear_traffic_routing.rb', line 26 def interval() jsii_get_property("interval") end |
#percentage ⇒ Numeric
The percentage to increase traffic on each traffic shift.
33 34 35 |
# File 'code_deploy/time_based_linear_traffic_routing.rb', line 33 def percentage() jsii_get_property("percentage") end |