Class: AWSCDK::Autoscaling::CfnAutoScalingGroup::AvailabilityZoneImpairmentPolicyProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
autoscaling/cfn_auto_scaling_group.rb

Overview

Describes an Availability Zone impairment policy.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(impaired_zone_health_check_behavior:, zonal_shift_enabled:) ⇒ AvailabilityZoneImpairmentPolicyProperty

Returns a new instance of AvailabilityZoneImpairmentPolicyProperty.

Parameters:

  • impaired_zone_health_check_behavior (String)

    Specifies the health check behavior for the impaired Availability Zone in an active zonal shift.

  • zonal_shift_enabled (Boolean, AWSCDK::IResolvable)

    If true , enable zonal shift for your Auto Scaling group.



1136
1137
1138
1139
1140
1141
# File 'autoscaling/cfn_auto_scaling_group.rb', line 1136

def initialize(impaired_zone_health_check_behavior:, zonal_shift_enabled:)
  @impaired_zone_health_check_behavior = impaired_zone_health_check_behavior
  Jsii::Type.check_type(@impaired_zone_health_check_behavior, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "impairedZoneHealthCheckBehavior")
  @zonal_shift_enabled = zonal_shift_enabled
  Jsii::Type.check_type(@zonal_shift_enabled, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "zonalShiftEnabled")
end

Instance Attribute Details

#impaired_zone_health_check_behaviorString (readonly)

Specifies the health check behavior for the impaired Availability Zone in an active zonal shift.

If you select Replace unhealthy , instances that appear unhealthy will be replaced in all Availability Zones. If you select Ignore unhealthy , instances will not be replaced in the Availability Zone with the active zonal shift. For more information, see Auto Scaling group zonal shift in the Amazon EC2 Auto Scaling User Guide .



1149
1150
1151
# File 'autoscaling/cfn_auto_scaling_group.rb', line 1149

def impaired_zone_health_check_behavior
  @impaired_zone_health_check_behavior
end

#zonal_shift_enabledBoolean, AWSCDK::IResolvable (readonly)

If true , enable zonal shift for your Auto Scaling group.



1154
1155
1156
# File 'autoscaling/cfn_auto_scaling_group.rb', line 1154

def zonal_shift_enabled
  @zonal_shift_enabled
end

Class Method Details

.jsii_propertiesObject



1156
1157
1158
1159
1160
1161
# File 'autoscaling/cfn_auto_scaling_group.rb', line 1156

def self.jsii_properties
  {
    :impaired_zone_health_check_behavior => "impairedZoneHealthCheckBehavior",
    :zonal_shift_enabled => "zonalShiftEnabled",
  }
end

Instance Method Details

#to_jsiiObject



1163
1164
1165
1166
1167
1168
1169
1170
# File 'autoscaling/cfn_auto_scaling_group.rb', line 1163

def to_jsii
  result = {}
  result.merge!({
    "impairedZoneHealthCheckBehavior" => @impaired_zone_health_check_behavior,
    "zonalShiftEnabled" => @zonal_shift_enabled,
  })
  result.compact
end