Class: AWSCDK::DynamoDB::CfnGlobalTable::TargetTrackingScalingPolicyConfigurationProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
dynamo_db/cfn_global_table.rb

Overview

Defines a target tracking scaling policy.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(target_value:, disable_scale_in: nil, scale_in_cooldown: nil, scale_out_cooldown: nil) ⇒ TargetTrackingScalingPolicyConfigurationProperty

Returns a new instance of TargetTrackingScalingPolicyConfigurationProperty.

Parameters:

  • target_value (Numeric)

    Defines a target value for the scaling policy.

  • disable_scale_in (Boolean, AWSCDK::IResolvable, nil) (defaults to: nil)

    Indicates whether scale in by the target tracking scaling policy is disabled.

  • scale_in_cooldown (Numeric, nil) (defaults to: nil)

    The amount of time, in seconds, after a scale-in activity completes before another scale-in activity can start.

  • scale_out_cooldown (Numeric, nil) (defaults to: nil)

    The amount of time, in seconds, after a scale-out activity completes before another scale-out activity can start.



1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
# File 'dynamo_db/cfn_global_table.rb', line 1959

def initialize(target_value:, disable_scale_in: nil, scale_in_cooldown: nil, scale_out_cooldown: nil)
  @target_value = target_value
  Jsii::Type.check_type(@target_value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "targetValue")
  @disable_scale_in = disable_scale_in
  Jsii::Type.check_type(@disable_scale_in, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "disableScaleIn") unless @disable_scale_in.nil?
  @scale_in_cooldown = scale_in_cooldown
  Jsii::Type.check_type(@scale_in_cooldown, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "scaleInCooldown") unless @scale_in_cooldown.nil?
  @scale_out_cooldown = scale_out_cooldown
  Jsii::Type.check_type(@scale_out_cooldown, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "scaleOutCooldown") unless @scale_out_cooldown.nil?
end

Instance Attribute Details

#disable_scale_inBoolean, ... (readonly)

Indicates whether scale in by the target tracking scaling policy is disabled.

The default value is false .



1981
1982
1983
# File 'dynamo_db/cfn_global_table.rb', line 1981

def disable_scale_in
  @disable_scale_in
end

#scale_in_cooldownNumeric? (readonly)

The amount of time, in seconds, after a scale-in activity completes before another scale-in activity can start.



1986
1987
1988
# File 'dynamo_db/cfn_global_table.rb', line 1986

def scale_in_cooldown
  @scale_in_cooldown
end

#scale_out_cooldownNumeric? (readonly)

The amount of time, in seconds, after a scale-out activity completes before another scale-out activity can start.



1991
1992
1993
# File 'dynamo_db/cfn_global_table.rb', line 1991

def scale_out_cooldown
  @scale_out_cooldown
end

#target_valueNumeric (readonly)

Defines a target value for the scaling policy.



1974
1975
1976
# File 'dynamo_db/cfn_global_table.rb', line 1974

def target_value
  @target_value
end

Class Method Details

.jsii_propertiesObject



1993
1994
1995
1996
1997
1998
1999
2000
# File 'dynamo_db/cfn_global_table.rb', line 1993

def self.jsii_properties
  {
    :target_value => "targetValue",
    :disable_scale_in => "disableScaleIn",
    :scale_in_cooldown => "scaleInCooldown",
    :scale_out_cooldown => "scaleOutCooldown",
  }
end

Instance Method Details

#to_jsiiObject



2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
# File 'dynamo_db/cfn_global_table.rb', line 2002

def to_jsii
  result = {}
  result.merge!({
    "targetValue" => @target_value,
    "disableScaleIn" => @disable_scale_in,
    "scaleInCooldown" => @scale_in_cooldown,
    "scaleOutCooldown" => @scale_out_cooldown,
  })
  result.compact
end