Class: AWSCDK::ElasticLoadBalancingv2::CfnListenerRuleProps

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

Overview

Properties for defining a CfnListenerRule.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(actions:, conditions:, priority:, listener_arn: nil, transforms: nil) ⇒ CfnListenerRuleProps

Returns a new instance of CfnListenerRuleProps.

Parameters:



14
15
16
17
18
19
20
21
22
23
24
25
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 14

def initialize(actions:, conditions:, priority:, listener_arn: nil, transforms: nil)
  @actions = actions
  Jsii::Type.check_type(@actions, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWxhc3RpY2xvYWRiYWxhbmNpbmd2Mi5DZm5MaXN0ZW5lclJ1bGUuQWN0aW9uUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "actions")
  @conditions = conditions
  Jsii::Type.check_type(@conditions, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWxhc3RpY2xvYWRiYWxhbmNpbmd2Mi5DZm5MaXN0ZW5lclJ1bGUuUnVsZUNvbmRpdGlvblByb3BlcnR5In1dfX0sImtpbmQiOiJhcnJheSJ9fV19fQ==")), "conditions")
  @priority = priority
  Jsii::Type.check_type(@priority, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "priority")
  @listener_arn = listener_arn
  Jsii::Type.check_type(@listener_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19lbGFzdGljbG9hZGJhbGFuY2luZ3YyLklMaXN0ZW5lclJlZiJ9XX19")), "listenerArn") unless @listener_arn.nil?
  @transforms = transforms
  Jsii::Type.check_type(@transforms, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWxhc3RpY2xvYWRiYWxhbmNpbmd2Mi5DZm5MaXN0ZW5lclJ1bGUuVHJhbnNmb3JtUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "transforms") unless @transforms.nil?
end

Instance Attribute Details

#actionsAWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::ElasticLoadBalancingv2::CfnListenerRule::ActionProperty> (readonly)

The actions.

The rule must include exactly one of the following types of actions: forward , fixed-response , or redirect , and it must be the last action to be performed. If the rule is for an HTTPS listener, it can also optionally include an authentication action.



33
34
35
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 33

def actions
  @actions
end

#conditionsAWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::ElasticLoadBalancingv2::CfnListenerRule::RuleConditionProperty> (readonly)

The conditions.

The rule can optionally include up to one of each of the following conditions: http-request-method , host-header , path-pattern , and source-ip . A rule can also optionally include one or more of each of the following conditions: http-header and query-string .



40
41
42
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 40

def conditions
  @conditions
end

#listener_arnString, ... (readonly)

The Amazon Resource Name (ARN) of the listener.



52
53
54
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 52

def listener_arn
  @listener_arn
end

#priorityNumeric (readonly)

The rule priority. A listener can't have multiple rules with the same priority.

If you try to reorder rules by updating their priorities, do not specify a new priority if an existing rule already uses this priority, as this can cause an error. If you need to reuse a priority with a different rule, you must remove it as a priority first, and then specify it in a subsequent update.



47
48
49
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 47

def priority
  @priority
end

Class Method Details

.jsii_propertiesObject



57
58
59
60
61
62
63
64
65
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 57

def self.jsii_properties
  {
    :actions => "actions",
    :conditions => "conditions",
    :priority => "priority",
    :listener_arn => "listenerArn",
    :transforms => "transforms",
  }
end

Instance Method Details

#to_jsiiObject



67
68
69
70
71
72
73
74
75
76
77
# File 'elastic_load_balancingv2/cfn_listener_rule_props.rb', line 67

def to_jsii
  result = {}
  result.merge!({
    "actions" => @actions,
    "conditions" => @conditions,
    "priority" => @priority,
    "listenerArn" => @listener_arn,
    "transforms" => @transforms,
  })
  result.compact
end