Class: AWSCDK::ElasticLoadBalancingv2::CfnListener::TargetGroupStickinessConfigProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
elastic_load_balancingv2/cfn_listener.rb

Overview

Information about the target group stickiness for a rule.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(duration_seconds: nil, enabled: nil) ⇒ TargetGroupStickinessConfigProperty

Returns a new instance of TargetGroupStickinessConfigProperty.

Parameters:

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

    [Application Load Balancers] The time period, in seconds, during which requests from a client should be routed to the same target group.

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

    Indicates whether target group stickiness is enabled.



1496
1497
1498
1499
1500
1501
# File 'elastic_load_balancingv2/cfn_listener.rb', line 1496

def initialize(duration_seconds: nil, enabled: nil)
  @duration_seconds = duration_seconds
  Jsii::Type.check_type(@duration_seconds, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "durationSeconds") unless @duration_seconds.nil?
  @enabled = enabled
  Jsii::Type.check_type(@enabled, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "enabled") unless @enabled.nil?
end

Instance Attribute Details

#duration_secondsNumeric? (readonly)

[Application Load Balancers] The time period, in seconds, during which requests from a client should be routed to the same target group.

The range is 1-604800 seconds (7 days). You must specify this value when enabling target group stickiness.



1509
1510
1511
# File 'elastic_load_balancingv2/cfn_listener.rb', line 1509

def duration_seconds
  @duration_seconds
end

#enabledBoolean, ... (readonly)

Indicates whether target group stickiness is enabled.



1514
1515
1516
# File 'elastic_load_balancingv2/cfn_listener.rb', line 1514

def enabled
  @enabled
end

Class Method Details

.jsii_propertiesObject



1516
1517
1518
1519
1520
1521
# File 'elastic_load_balancingv2/cfn_listener.rb', line 1516

def self.jsii_properties
  {
    :duration_seconds => "durationSeconds",
    :enabled => "enabled",
  }
end

Instance Method Details

#to_jsiiObject



1523
1524
1525
1526
1527
1528
1529
1530
# File 'elastic_load_balancingv2/cfn_listener.rb', line 1523

def to_jsii
  result = {}
  result.merge!({
    "durationSeconds" => @duration_seconds,
    "enabled" => @enabled,
  })
  result.compact
end