Table of Contents

Interface CfnLoadBalancer.IListenersProperty

Namespace
Amazon.CDK.AWS.ElasticLoadBalancing
Assembly
Amazon.CDK.AWS.ElasticLoadBalancing.dll

Specifies a listener for your Classic Load Balancer.

public interface CfnLoadBalancer.IListenersProperty

Examples

// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.ElasticLoadBalancing;

             var listenersProperty = new ListenersProperty {
                 InstancePort = "instancePort",
                 LoadBalancerPort = "loadBalancerPort",
                 Protocol = "protocol",

                 // the properties below are optional
                 InstanceProtocol = "instanceProtocol",
                 PolicyNames = new [] { "policyNames" },
                 SslCertificateId = "sslCertificateId"
             };

Remarks

Modifying any property replaces the listener.

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-elb-listener.html

ExampleMetadata: fixture=_generated

Properties

InstancePort

The port on which the instance is listening.

string InstancePort { get; }

Property Value

string

Remarks

InstanceProtocol

The protocol to use for routing traffic to instances: HTTP, HTTPS, TCP, or SSL.

string? InstanceProtocol { get; }

Property Value

string

Remarks

If the front-end protocol is TCP or SSL, the back-end protocol must be TCP or SSL. If the front-end protocol is HTTP or HTTPS, the back-end protocol must be HTTP or HTTPS.

If there is another listener with the same InstancePort whose InstanceProtocol is secure, (HTTPS or SSL), the listener's InstanceProtocol must also be secure.

If there is another listener with the same InstancePort whose InstanceProtocol is HTTP or TCP, the listener's InstanceProtocol must be HTTP or TCP.

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-elb-listener.html#cfn-ec2-elb-listener-instanceprotocol

LoadBalancerPort

The port on which the load balancer is listening.

string LoadBalancerPort { get; }

Property Value

string

Remarks

On EC2-VPC, you can specify any port from the range 1-65535. On EC2-Classic, you can specify any port from the following list: 25, 80, 443, 465, 587, 1024-65535.

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-elb-listener.html#cfn-ec2-elb-listener-loadbalancerport

PolicyNames

The names of the policies to associate with the listener.

string[]? PolicyNames { get; }

Property Value

string[]

Remarks

Protocol

The load balancer transport protocol to use for routing: HTTP, HTTPS, TCP, or SSL.

string Protocol { get; }

Property Value

string

Remarks

SslCertificateId

The Amazon Resource Name (ARN) of the server certificate.

string? SslCertificateId { get; }

Property Value

string

Remarks