Class: AWSCDK::ElasticLoadBalancingv2::CfnTargetGroup::TargetDescriptionProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::ElasticLoadBalancingv2::CfnTargetGroup::TargetDescriptionProperty
- Defined in:
- elastic_load_balancingv2/cfn_target_group.rb
Overview
Specifies a target to add to a target group.
Instance Attribute Summary collapse
-
#availability_zone ⇒ String?
readonly
An Availability Zone or
all. -
#id ⇒ String
readonly
The ID of the target.
-
#port ⇒ Numeric?
readonly
The port on which the target is listening.
-
#quic_server_id ⇒ String?
readonly
The server ID for the targets.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id:, availability_zone: nil, port: nil, quic_server_id: nil) ⇒ TargetDescriptionProperty
constructor
A new instance of TargetDescriptionProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(id:, availability_zone: nil, port: nil, quic_server_id: nil) ⇒ TargetDescriptionProperty
Returns a new instance of TargetDescriptionProperty.
851 852 853 854 855 856 857 858 859 860 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 851 def initialize(id:, availability_zone: nil, port: nil, quic_server_id: nil) @id = id Jsii::Type.check_type(@id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "id") @availability_zone = availability_zone Jsii::Type.check_type(@availability_zone, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "availabilityZone") unless @availability_zone.nil? @port = port Jsii::Type.check_type(@port, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "port") unless @port.nil? @quic_server_id = quic_server_id Jsii::Type.check_type(@quic_server_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "quicServerId") unless @quic_server_id.nil? end |
Instance Attribute Details
#availability_zone ⇒ String? (readonly)
An Availability Zone or all .
This determines whether the target receives traffic from the load balancer nodes in the specified Availability Zone or from all enabled Availability Zones for the load balancer.
For Application Load Balancer target groups, the specified Availability Zone value is only applicable when cross-zone load balancing is off. Otherwise the parameter is ignored and treated as all .
This parameter is not supported if the target type of the target group is instance or alb .
If the target type is ip and the IP address is in a subnet of the VPC for the target group, the Availability Zone is automatically detected and this parameter is optional. If the IP address is outside the VPC, this parameter is required.
For Application Load Balancer target groups with cross-zone load balancing off, if the target type is ip and the IP address is outside of the VPC for the target group, this should be an Availability Zone inside the VPC for the target group.
If the target type is lambda , this parameter is optional and the only supported value is all .
885 886 887 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 885 def availability_zone @availability_zone end |
#id ⇒ String (readonly)
The ID of the target.
If the target type of the target group is instance , specify an instance ID. If the target type is ip , specify an IP address. If the target type is lambda , specify the ARN of the Lambda function. If the target type is alb , specify the ARN of the Application Load Balancer target.
868 869 870 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 868 def id @id end |
#port ⇒ Numeric? (readonly)
The port on which the target is listening.
If the target group protocol is GENEVE, the supported port is 6081. If the target type is alb , the targeted Application Load Balancer must have at least one listener whose port matches the target group port. This parameter is not used if the target is a Lambda function.
892 893 894 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 892 def port @port end |
#quic_server_id ⇒ String? (readonly)
The server ID for the targets.
This value is required if the protocol is QUIC or TCP_QUIC and can't be used with other protocols.
The ID consists of the 0x prefix followed by 16 hexadecimal characters. Any letters must be lowercase. The value must be unique at the listener level. You can't modify the server ID for a registered target. You must deregister the target and then provide a new server ID when you register the target again.
901 902 903 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 901 def quic_server_id @quic_server_id end |
Class Method Details
.jsii_properties ⇒ Object
903 904 905 906 907 908 909 910 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 903 def self.jsii_properties { :id => "id", :availability_zone => "availabilityZone", :port => "port", :quic_server_id => "quicServerId", } end |
Instance Method Details
#to_jsii ⇒ Object
912 913 914 915 916 917 918 919 920 921 |
# File 'elastic_load_balancingv2/cfn_target_group.rb', line 912 def to_jsii result = {} result.merge!({ "id" => @id, "availabilityZone" => @availability_zone, "port" => @port, "quicServerId" => @quic_server_id, }) result.compact end |