Listener

class aws_cdk.aws_globalaccelerator.Listener(scope, id, *, accelerator, port_ranges, client_affinity=None, listener_name=None, protocol=None)

Bases: aws_cdk.core.Resource

(experimental) The construct for the Listener.

Stability

experimental

Parameters
  • scope (Construct) –

  • id (str) –

  • accelerator (IAccelerator) – (experimental) The accelerator for this listener.

  • port_ranges (List[PortRange]) – (experimental) The list of port ranges for the connections from clients to the accelerator.

  • client_affinity (Optional[ClientAffinity]) – (experimental) Client affinity to direct all requests from a user to the same endpoint. Default: NONE

  • listener_name (Optional[str]) – (experimental) Name of the listener. Default: - logical ID of the resource

  • protocol (Optional[ConnectionProtocol]) – (experimental) The protocol for the connections from clients to the accelerator. Default: TCP

Stability

experimental

Methods

to_string()

Returns a string representation of this construct.

Return type

str

Attributes

env

The environment this resource belongs to.

For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.

Return type

ResourceEnvironment

listener_arn

(experimental) The ARN of the listener.

Stability

experimental

Return type

str

listener_name

(experimental) The name of the listener.

Stability

experimental

Attribute

true

Return type

str

node

The construct tree node associated with this construct.

Return type

ConstructNode

stack

The stack in which this resource is defined.

Return type

Stack

Static Methods

classmethod from_listener_arn(scope, id, listener_arn)

(experimental) import from ARN.

Parameters
  • scope (Construct) –

  • id (str) –

  • listener_arn (str) –

Stability

experimental

Return type

IListener

classmethod is_construct(x)

Return whether the given object is a Construct.

Parameters

x (Any) –

Return type

bool