Class: AWSCDK::CodeDeploy::CfnDeploymentConfig::TimeBasedLinearProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
code_deploy/cfn_deployment_config.rb

Overview

A configuration that shifts traffic from one version of a Lambda function or ECS task set to another in equal increments, with an equal number of minutes between each increment.

The original and target Lambda function versions or ECS task sets are specified in the deployment's AppSpec file.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(linear_interval:, linear_percentage:) ⇒ TimeBasedLinearProperty

Returns a new instance of TimeBasedLinearProperty.

Parameters:

  • linear_interval (Numeric)

    The number of minutes between each incremental traffic shift of a TimeBasedLinear deployment.

  • linear_percentage (Numeric)

    The percentage of traffic that is shifted at the start of each increment of a TimeBasedLinear deployment.



692
693
694
695
696
697
# File 'code_deploy/cfn_deployment_config.rb', line 692

def initialize(linear_interval:, linear_percentage:)
  @linear_interval = linear_interval
  Jsii::Type.check_type(@linear_interval, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "linearInterval")
  @linear_percentage = linear_percentage
  Jsii::Type.check_type(@linear_percentage, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "linearPercentage")
end

Instance Attribute Details

#linear_intervalNumeric (readonly)

The number of minutes between each incremental traffic shift of a TimeBasedLinear deployment.



703
704
705
# File 'code_deploy/cfn_deployment_config.rb', line 703

def linear_interval
  @linear_interval
end

#linear_percentageNumeric (readonly)

The percentage of traffic that is shifted at the start of each increment of a TimeBasedLinear deployment.



708
709
710
# File 'code_deploy/cfn_deployment_config.rb', line 708

def linear_percentage
  @linear_percentage
end

Class Method Details

.jsii_propertiesObject



710
711
712
713
714
715
# File 'code_deploy/cfn_deployment_config.rb', line 710

def self.jsii_properties
  {
    :linear_interval => "linearInterval",
    :linear_percentage => "linearPercentage",
  }
end

Instance Method Details

#to_jsiiObject



717
718
719
720
721
722
723
724
# File 'code_deploy/cfn_deployment_config.rb', line 717

def to_jsii
  result = {}
  result.merge!({
    "linearInterval" => @linear_interval,
    "linearPercentage" => @linear_percentage,
  })
  result.compact
end