aws-cdk-lib.aws_ecs_patterns.ApplicationLoadBalancedServiceBase

class ApplicationLoadBalancedServiceBase

LanguageType name
.NETAmazon.CDK.AWS.ECS.Patterns.ApplicationLoadBalancedServiceBase
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsecspatterns#ApplicationLoadBalancedServiceBase
Javasoftware.amazon.awscdk.services.ecs.patterns.ApplicationLoadBalancedServiceBase
Pythonaws_cdk.aws_ecs_patterns.ApplicationLoadBalancedServiceBase
TypeScript (source)aws-cdk-lib » aws_ecs_patterns » ApplicationLoadBalancedServiceBase

Implements IConstruct, IDependable

Extends Construct

Implemented by ApplicationLoadBalancedEc2Service, ApplicationLoadBalancedFargateService

The base class for ApplicationLoadBalancedEc2Service and ApplicationLoadBalancedFargateService services.

Initializer

new ApplicationLoadBalancedServiceBase(scope: Construct, id: string, props?: ApplicationLoadBalancedServiceBaseProps)

Parameters

  • scope Construct
  • id string
  • props ApplicationLoadBalancedServiceBaseProps

Constructs a new instance of the ApplicationLoadBalancedServiceBase class.

Properties

NameTypeDescription
clusterIClusterThe cluster that hosts the service.
listenerApplicationListenerThe listener for the service.
loadBalancerApplicationLoadBalancerThe Application Load Balancer for the service.
nodeNodeThe tree node.
targetGroupApplicationTargetGroupThe target group for the service.
certificate?ICertificateCertificate Manager certificate to associate with the load balancer.
internalDesiredCount?numberThe desired number of instantiations of the task definition to keep running on the service.
redirectListener?ApplicationListenerThe redirect listener for the service if redirectHTTP is enabled.

cluster

Type: ICluster

The cluster that hosts the service.


listener

Type: ApplicationListener

The listener for the service.


loadBalancer

Type: ApplicationLoadBalancer

The Application Load Balancer for the service.


node

Type: Node

The tree node.


targetGroup

Type: ApplicationTargetGroup

The target group for the service.


certificate?

Type: ICertificate (optional)

Certificate Manager certificate to associate with the load balancer.


internalDesiredCount?

Type: number (optional)

The desired number of instantiations of the task definition to keep running on the service.

The default is 1 for all new services and uses the existing services desired count when updating an existing service if one is not provided.


redirectListener?

Type: ApplicationListener (optional)

The redirect listener for the service if redirectHTTP is enabled.

Methods

NameDescription
toString()Returns a string representation of this construct.
protected addServiceAsTarget(service)Adds service as a target of the target group.
protected createAWSLogDriver(prefix)
protected getDefaultCluster(scope, vpc?)Returns the default cluster.

toString()

public toString(): string

Returns

  • string

Returns a string representation of this construct.


protected addServiceAsTarget(service)

protected addServiceAsTarget(service: BaseService): void

Parameters

  • service BaseService

Adds service as a target of the target group.


protected createAWSLogDriver(prefix)

protected createAWSLogDriver(prefix: string): AwsLogDriver

Parameters

  • prefix string

Returns

  • AwsLogDriver

protected getDefaultCluster(scope, vpc?)

protected getDefaultCluster(scope: Construct, vpc?: IVpc): Cluster

Parameters

  • scope Construct
  • vpc IVpc

Returns

  • Cluster

Returns the default cluster.