Class: AWSCDK::StepFunctionsTasks::EMRCreateCluster::ScalingConstraintsProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
step_functions_tasks/emr_create_cluster.rb

Overview

The upper and lower EC2 instance limits for an automatic scaling policy.

Automatic scaling activities triggered by automatic scaling rules will not cause an instance group to grow above or below these limits.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(max_capacity:, min_capacity:) ⇒ ScalingConstraintsProperty

Returns a new instance of ScalingConstraintsProperty.

Parameters:

  • max_capacity (Numeric)

    The upper boundary of EC2 instances in an instance group beyond which scaling activities are not allowed to grow.

  • min_capacity (Numeric)

    The lower boundary of EC2 instances in an instance group below which scaling activities are not allowed to shrink.



2342
2343
2344
2345
2346
2347
# File 'step_functions_tasks/emr_create_cluster.rb', line 2342

def initialize(max_capacity:, min_capacity:)
  @max_capacity = max_capacity
  Jsii::Type.check_type(@max_capacity, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "maxCapacity")
  @min_capacity = min_capacity
  Jsii::Type.check_type(@min_capacity, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "minCapacity")
end

Instance Attribute Details

#max_capacityNumeric (readonly)

The upper boundary of EC2 instances in an instance group beyond which scaling activities are not allowed to grow.

Scale-out activities will not add instances beyond this boundary.

Returns:

  • (Numeric)


2355
2356
2357
# File 'step_functions_tasks/emr_create_cluster.rb', line 2355

def max_capacity
  @max_capacity
end

#min_capacityNumeric (readonly)

The lower boundary of EC2 instances in an instance group below which scaling activities are not allowed to shrink.

Scale-in activities will not terminate instances below this boundary.

Returns:

  • (Numeric)


2362
2363
2364
# File 'step_functions_tasks/emr_create_cluster.rb', line 2362

def min_capacity
  @min_capacity
end

Class Method Details

.jsii_propertiesObject



2364
2365
2366
2367
2368
2369
# File 'step_functions_tasks/emr_create_cluster.rb', line 2364

def self.jsii_properties
  {
    :max_capacity => "maxCapacity",
    :min_capacity => "minCapacity",
  }
end

Instance Method Details

#to_jsiiObject



2371
2372
2373
2374
2375
2376
2377
2378
# File 'step_functions_tasks/emr_create_cluster.rb', line 2371

def to_jsii
  result = {}
  result.merge!({
    "maxCapacity" => @max_capacity,
    "minCapacity" => @min_capacity,
  })
  result.compact
end