Class: AWSCDK::AutoScalingPlans::CfnScalingPlanProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
auto_scaling_plans/cfn_scaling_plan_props.rb

Overview

Properties for defining a CfnScalingPlan.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(application_source:, scaling_instructions:) ⇒ CfnScalingPlanProps

Returns a new instance of CfnScalingPlanProps.

Parameters:



11
12
13
14
15
16
# File 'auto_scaling_plans/cfn_scaling_plan_props.rb', line 11

def initialize(application_source:, scaling_instructions:)
  @application_source = application_source.is_a?(Hash) ? ::AWSCDK::AutoScalingPlans::CfnScalingPlan::ApplicationSourceProperty.new(**application_source.transform_keys(&:to_sym)) : application_source
  Jsii::Type.check_type(@application_source, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19hdXRvc2NhbGluZ3BsYW5zLkNmblNjYWxpbmdQbGFuLkFwcGxpY2F0aW9uU291cmNlUHJvcGVydHkifV19fQ==")), "applicationSource")
  @scaling_instructions = scaling_instructions
  Jsii::Type.check_type(@scaling_instructions, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXV0b3NjYWxpbmdwbGFucy5DZm5TY2FsaW5nUGxhbi5TY2FsaW5nSW5zdHJ1Y3Rpb25Qcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "scalingInstructions")
end

Instance Attribute Details

#application_sourceAWSCDK::IResolvable, AWSCDK::AutoScalingPlans::CfnScalingPlan::ApplicationSourceProperty (readonly)

A CloudFormation stack or a set of tags.

You can create one scaling plan per application source. The ApplicationSource property must be present to ensure interoperability with the AWS Auto Scaling console.



24
25
26
# File 'auto_scaling_plans/cfn_scaling_plan_props.rb', line 24

def application_source
  @application_source
end

Class Method Details

.jsii_propertiesObject



31
32
33
34
35
36
# File 'auto_scaling_plans/cfn_scaling_plan_props.rb', line 31

def self.jsii_properties
  {
    :application_source => "applicationSource",
    :scaling_instructions => "scalingInstructions",
  }
end

Instance Method Details

#to_jsiiObject



38
39
40
41
42
43
44
45
# File 'auto_scaling_plans/cfn_scaling_plan_props.rb', line 38

def to_jsii
  result = {}
  result.merge!({
    "applicationSource" => @application_source,
    "scalingInstructions" => @scaling_instructions,
  })
  result.compact
end