UNPKG

@cdklabs/cdk-ecs-codedeploy

Version:

CDK Constructs for performing ECS Deployments with CodeDeploy

1,217 lines (752 loc) 105 kB
# API Reference <a name="API Reference" id="api-reference"></a> ## Constructs <a name="Constructs" id="Constructs"></a> ### ApiCanary <a name="ApiCanary" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary"></a> A CloudWatch Synthetic Canary for monitoring APIs. #### Initializers <a name="Initializers" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer"></a> ```typescript import { ApiCanary } from '@cdklabs/cdk-ecs-codedeploy' new ApiCanary(scope: Construct, id: string, props: ApiCanaryProps) ``` | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.scope">scope</a></code> | <code>constructs.Construct</code> | *No description.* | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.id">id</a></code> | <code>string</code> | *No description.* | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.props">props</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps">ApiCanaryProps</a></code> | *No description.* | --- ##### `scope`<sup>Required</sup> <a name="scope" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.scope"></a> - *Type:* constructs.Construct --- ##### `id`<sup>Required</sup> <a name="id" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.id"></a> - *Type:* string --- ##### `props`<sup>Required</sup> <a name="props" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.Initializer.parameter.props"></a> - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps">ApiCanaryProps</a> --- #### Methods <a name="Methods" id="Methods"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.toString">toString</a></code> | Returns a string representation of this construct. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.applyRemovalPolicy">applyRemovalPolicy</a></code> | Apply the given removal policy to this resource. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricDuration">metricDuration</a></code> | Measure the Duration of a single canary run, in seconds. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricFailed">metricFailed</a></code> | Measure the number of failed canary runs over a given time period. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricSuccessPercent">metricSuccessPercent</a></code> | Measure the percentage of successful canary runs. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.addTestStep">addTestStep</a></code> | Add a new test step to this canary. | --- ##### `toString` <a name="toString" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.toString"></a> ```typescript public toString(): string ``` Returns a string representation of this construct. ##### `applyRemovalPolicy` <a name="applyRemovalPolicy" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.applyRemovalPolicy"></a> ```typescript public applyRemovalPolicy(policy: RemovalPolicy): void ``` Apply the given removal policy to this resource. The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced. The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). ###### `policy`<sup>Required</sup> <a name="policy" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.applyRemovalPolicy.parameter.policy"></a> - *Type:* aws-cdk-lib.RemovalPolicy --- ##### `metricDuration` <a name="metricDuration" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricDuration"></a> ```typescript public metricDuration(options?: MetricOptions): Metric ``` Measure the Duration of a single canary run, in seconds. ###### `options`<sup>Optional</sup> <a name="options" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricDuration.parameter.options"></a> - *Type:* aws-cdk-lib.aws_cloudwatch.MetricOptions configuration options for the metric. --- ##### `metricFailed` <a name="metricFailed" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricFailed"></a> ```typescript public metricFailed(options?: MetricOptions): Metric ``` Measure the number of failed canary runs over a given time period. Default: sum over 5 minutes ###### `options`<sup>Optional</sup> <a name="options" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricFailed.parameter.options"></a> - *Type:* aws-cdk-lib.aws_cloudwatch.MetricOptions configuration options for the metric. --- ##### `metricSuccessPercent` <a name="metricSuccessPercent" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricSuccessPercent"></a> ```typescript public metricSuccessPercent(options?: MetricOptions): Metric ``` Measure the percentage of successful canary runs. ###### `options`<sup>Optional</sup> <a name="options" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.metricSuccessPercent.parameter.options"></a> - *Type:* aws-cdk-lib.aws_cloudwatch.MetricOptions configuration options for the metric. --- ##### `addTestStep` <a name="addTestStep" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.addTestStep"></a> ```typescript public addTestStep(step: ApiTestStep): void ``` Add a new test step to this canary. ###### `step`<sup>Required</sup> <a name="step" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.addTestStep.parameter.step"></a> - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep">ApiTestStep</a> ApiTestStep to add. --- #### Static Functions <a name="Static Functions" id="Static Functions"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.isOwnedResource">isOwnedResource</a></code> | Returns true if the construct was created by CDK, and false otherwise. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.isResource">isResource</a></code> | Check whether the given construct is a Resource. | --- ##### ~~`isConstruct`~~ <a name="isConstruct" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isConstruct"></a> ```typescript import { ApiCanary } from '@cdklabs/cdk-ecs-codedeploy' ApiCanary.isConstruct(x: any) ``` Checks if `x` is a construct. ###### `x`<sup>Required</sup> <a name="x" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isConstruct.parameter.x"></a> - *Type:* any Any object. --- ##### `isOwnedResource` <a name="isOwnedResource" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isOwnedResource"></a> ```typescript import { ApiCanary } from '@cdklabs/cdk-ecs-codedeploy' ApiCanary.isOwnedResource(construct: IConstruct) ``` Returns true if the construct was created by CDK, and false otherwise. ###### `construct`<sup>Required</sup> <a name="construct" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isOwnedResource.parameter.construct"></a> - *Type:* constructs.IConstruct --- ##### `isResource` <a name="isResource" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isResource"></a> ```typescript import { ApiCanary } from '@cdklabs/cdk-ecs-codedeploy' ApiCanary.isResource(construct: IConstruct) ``` Check whether the given construct is a Resource. ###### `construct`<sup>Required</sup> <a name="construct" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.isResource.parameter.construct"></a> - *Type:* constructs.IConstruct --- #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.env">env</a></code> | <code>aws-cdk-lib.ResourceEnvironment</code> | The environment this resource belongs to. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.stack">stack</a></code> | <code>aws-cdk-lib.Stack</code> | The stack in which this resource is defined. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.artifactsBucket">artifactsBucket</a></code> | <code>aws-cdk-lib.aws_s3.IBucket</code> | Bucket where data from each canary run is stored. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryId">canaryId</a></code> | <code>string</code> | The canary ID. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryName">canaryName</a></code> | <code>string</code> | The canary Name. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryState">canaryState</a></code> | <code>string</code> | The state of the canary. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.connections">connections</a></code> | <code>aws-cdk-lib.aws_ec2.Connections</code> | Access the Connections object. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.role">role</a></code> | <code>aws-cdk-lib.aws_iam.IRole</code> | Execution role associated with this Canary. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.successAlarm">successAlarm</a></code> | <code>aws-cdk-lib.aws_cloudwatch.Alarm</code> | A CloudWatch Alarm that triggers when the success rate falls below 100% over the past 2 periods. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.durationAlarm">durationAlarm</a></code> | <code>aws-cdk-lib.aws_cloudwatch.Alarm</code> | A CloudWatch Alarm that triggers when the duration of the tests exceeds the given threshold over the past 2 periods. | --- ##### `node`<sup>Required</sup> <a name="node" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.node"></a> ```typescript public readonly node: Node; ``` - *Type:* constructs.Node The tree node. --- ##### `env`<sup>Required</sup> <a name="env" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.env"></a> ```typescript public readonly env: ResourceEnvironment; ``` - *Type:* aws-cdk-lib.ResourceEnvironment 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. --- ##### `stack`<sup>Required</sup> <a name="stack" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.stack"></a> ```typescript public readonly stack: Stack; ``` - *Type:* aws-cdk-lib.Stack The stack in which this resource is defined. --- ##### `artifactsBucket`<sup>Required</sup> <a name="artifactsBucket" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.artifactsBucket"></a> ```typescript public readonly artifactsBucket: IBucket; ``` - *Type:* aws-cdk-lib.aws_s3.IBucket Bucket where data from each canary run is stored. --- ##### `canaryId`<sup>Required</sup> <a name="canaryId" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryId"></a> ```typescript public readonly canaryId: string; ``` - *Type:* string The canary ID. --- ##### `canaryName`<sup>Required</sup> <a name="canaryName" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryName"></a> ```typescript public readonly canaryName: string; ``` - *Type:* string The canary Name. --- ##### `canaryState`<sup>Required</sup> <a name="canaryState" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.canaryState"></a> ```typescript public readonly canaryState: string; ``` - *Type:* string The state of the canary. For example, 'RUNNING', 'STOPPED', 'NOT STARTED', or 'ERROR'. --- ##### `connections`<sup>Required</sup> <a name="connections" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.connections"></a> ```typescript public readonly connections: Connections; ``` - *Type:* aws-cdk-lib.aws_ec2.Connections Access the Connections object. Will fail if not a VPC-enabled Canary --- ##### `role`<sup>Required</sup> <a name="role" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.role"></a> ```typescript public readonly role: IRole; ``` - *Type:* aws-cdk-lib.aws_iam.IRole Execution role associated with this Canary. --- ##### `successAlarm`<sup>Required</sup> <a name="successAlarm" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.successAlarm"></a> ```typescript public readonly successAlarm: Alarm; ``` - *Type:* aws-cdk-lib.aws_cloudwatch.Alarm A CloudWatch Alarm that triggers when the success rate falls below 100% over the past 2 periods. --- ##### `durationAlarm`<sup>Optional</sup> <a name="durationAlarm" id="@cdklabs/cdk-ecs-codedeploy.ApiCanary.property.durationAlarm"></a> ```typescript public readonly durationAlarm: Alarm; ``` - *Type:* aws-cdk-lib.aws_cloudwatch.Alarm A CloudWatch Alarm that triggers when the duration of the tests exceeds the given threshold over the past 2 periods. --- ### ApplicationLoadBalancedCodeDeployedFargateService <a name="ApplicationLoadBalancedCodeDeployedFargateService" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService"></a> A Fargate service running on an ECS cluster fronted by an application load balancer and deployed by CodeDeploy. #### Initializers <a name="Initializers" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer"></a> ```typescript import { ApplicationLoadBalancedCodeDeployedFargateService } from '@cdklabs/cdk-ecs-codedeploy' new ApplicationLoadBalancedCodeDeployedFargateService(scope: Construct, id: string, props: ApplicationLoadBalancedCodeDeployedFargateServiceProps) ``` | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.scope">scope</a></code> | <code>constructs.Construct</code> | *No description.* | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.id">id</a></code> | <code>string</code> | *No description.* | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.props">props</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps">ApplicationLoadBalancedCodeDeployedFargateServiceProps</a></code> | *No description.* | --- ##### `scope`<sup>Required</sup> <a name="scope" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.scope"></a> - *Type:* constructs.Construct --- ##### `id`<sup>Required</sup> <a name="id" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.id"></a> - *Type:* string --- ##### `props`<sup>Required</sup> <a name="props" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.Initializer.parameter.props"></a> - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps">ApplicationLoadBalancedCodeDeployedFargateServiceProps</a> --- #### Methods <a name="Methods" id="Methods"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.toString">toString</a></code> | Returns a string representation of this construct. | --- ##### `toString` <a name="toString" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.toString"></a> ```typescript public toString(): string ``` Returns a string representation of this construct. #### Static Functions <a name="Static Functions" id="Static Functions"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. | --- ##### ~~`isConstruct`~~ <a name="isConstruct" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.isConstruct"></a> ```typescript import { ApplicationLoadBalancedCodeDeployedFargateService } from '@cdklabs/cdk-ecs-codedeploy' ApplicationLoadBalancedCodeDeployedFargateService.isConstruct(x: any) ``` Checks if `x` is a construct. ###### `x`<sup>Required</sup> <a name="x" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.isConstruct.parameter.x"></a> - *Type:* any Any object. --- #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.cluster">cluster</a></code> | <code>aws-cdk-lib.aws_ecs.ICluster</code> | The cluster that hosts the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.listener">listener</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener</code> | The listener for the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.loadBalancer">loadBalancer</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer</code> | The Application Load Balancer for the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.targetGroup">targetGroup</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup</code> | The target group for the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.certificate">certificate</a></code> | <code>aws-cdk-lib.aws_certificatemanager.ICertificate</code> | Certificate Manager certificate to associate with the load balancer. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.internalDesiredCount">internalDesiredCount</a></code> | <code>number</code> | The desired number of instantiations of the task definition to keep running on the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.redirectListener">redirectListener</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener</code> | The redirect listener for the service if redirectHTTP is enabled. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.assignPublicIp">assignPublicIp</a></code> | <code>boolean</code> | Determines whether the service will be assigned a public IP address. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.service">service</a></code> | <code>aws-cdk-lib.aws_ecs.FargateService</code> | The Fargate service in this construct. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.taskDefinition">taskDefinition</a></code> | <code>aws-cdk-lib.aws_ecs.FargateTaskDefinition</code> | The Fargate task definition in this construct. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.accessLogBucket">accessLogBucket</a></code> | <code>aws-cdk-lib.aws_s3.IBucket</code> | S3 Bucket used for access logs. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.application">application</a></code> | <code>aws-cdk-lib.aws_codedeploy.EcsApplication</code> | CodeDeploy application for this service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.deployment">deployment</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment">EcsDeployment</a></code> | CodeDeploy deployment for this service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.deploymentGroup">deploymentGroup</a></code> | <code>aws-cdk-lib.aws_codedeploy.EcsDeploymentGroup</code> | CodeDeploy deployment group for this service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.greenTargetGroup">greenTargetGroup</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup</code> | Test target group to use for CodeDeploy deployments. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.testListener">testListener</a></code> | <code>aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener</code> | Test listener to use for CodeDeploy deployments. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.apiCanary">apiCanary</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary">ApiCanary</a></code> | API Canary for the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.healthAlarm">healthAlarm</a></code> | <code>aws-cdk-lib.aws_cloudwatch.IAlarm</code> | Composite alarm for monitoring health of service. | --- ##### `node`<sup>Required</sup> <a name="node" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.node"></a> ```typescript public readonly node: Node; ``` - *Type:* constructs.Node The tree node. --- ##### `cluster`<sup>Required</sup> <a name="cluster" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.cluster"></a> ```typescript public readonly cluster: ICluster; ``` - *Type:* aws-cdk-lib.aws_ecs.ICluster The cluster that hosts the service. --- ##### `listener`<sup>Required</sup> <a name="listener" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.listener"></a> ```typescript public readonly listener: ApplicationListener; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener The listener for the service. --- ##### `loadBalancer`<sup>Required</sup> <a name="loadBalancer" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.loadBalancer"></a> ```typescript public readonly loadBalancer: ApplicationLoadBalancer; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer The Application Load Balancer for the service. --- ##### `targetGroup`<sup>Required</sup> <a name="targetGroup" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.targetGroup"></a> ```typescript public readonly targetGroup: ApplicationTargetGroup; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup The target group for the service. --- ##### `certificate`<sup>Optional</sup> <a name="certificate" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.certificate"></a> ```typescript public readonly certificate: ICertificate; ``` - *Type:* aws-cdk-lib.aws_certificatemanager.ICertificate Certificate Manager certificate to associate with the load balancer. --- ##### `internalDesiredCount`<sup>Optional</sup> <a name="internalDesiredCount" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.internalDesiredCount"></a> ```typescript public readonly internalDesiredCount: number; ``` - *Type:* number 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`<sup>Optional</sup> <a name="redirectListener" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.redirectListener"></a> ```typescript public readonly redirectListener: ApplicationListener; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener The redirect listener for the service if redirectHTTP is enabled. --- ##### `assignPublicIp`<sup>Required</sup> <a name="assignPublicIp" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.assignPublicIp"></a> ```typescript public readonly assignPublicIp: boolean; ``` - *Type:* boolean Determines whether the service will be assigned a public IP address. --- ##### `service`<sup>Required</sup> <a name="service" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.service"></a> ```typescript public readonly service: FargateService; ``` - *Type:* aws-cdk-lib.aws_ecs.FargateService The Fargate service in this construct. --- ##### `taskDefinition`<sup>Required</sup> <a name="taskDefinition" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.taskDefinition"></a> ```typescript public readonly taskDefinition: FargateTaskDefinition; ``` - *Type:* aws-cdk-lib.aws_ecs.FargateTaskDefinition The Fargate task definition in this construct. --- ##### `accessLogBucket`<sup>Required</sup> <a name="accessLogBucket" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.accessLogBucket"></a> ```typescript public readonly accessLogBucket: IBucket; ``` - *Type:* aws-cdk-lib.aws_s3.IBucket S3 Bucket used for access logs. --- ##### `application`<sup>Required</sup> <a name="application" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.application"></a> ```typescript public readonly application: EcsApplication; ``` - *Type:* aws-cdk-lib.aws_codedeploy.EcsApplication CodeDeploy application for this service. --- ##### `deployment`<sup>Required</sup> <a name="deployment" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.deployment"></a> ```typescript public readonly deployment: EcsDeployment; ``` - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment">EcsDeployment</a> CodeDeploy deployment for this service. --- ##### `deploymentGroup`<sup>Required</sup> <a name="deploymentGroup" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.deploymentGroup"></a> ```typescript public readonly deploymentGroup: EcsDeploymentGroup; ``` - *Type:* aws-cdk-lib.aws_codedeploy.EcsDeploymentGroup CodeDeploy deployment group for this service. --- ##### `greenTargetGroup`<sup>Required</sup> <a name="greenTargetGroup" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.greenTargetGroup"></a> ```typescript public readonly greenTargetGroup: ApplicationTargetGroup; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup Test target group to use for CodeDeploy deployments. --- ##### `testListener`<sup>Required</sup> <a name="testListener" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.testListener"></a> ```typescript public readonly testListener: ApplicationListener; ``` - *Type:* aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener Test listener to use for CodeDeploy deployments. --- ##### `apiCanary`<sup>Optional</sup> <a name="apiCanary" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.apiCanary"></a> ```typescript public readonly apiCanary: ApiCanary; ``` - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanary">ApiCanary</a> API Canary for the service. --- ##### `healthAlarm`<sup>Optional</sup> <a name="healthAlarm" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateService.property.healthAlarm"></a> ```typescript public readonly healthAlarm: IAlarm; ``` - *Type:* aws-cdk-lib.aws_cloudwatch.IAlarm Composite alarm for monitoring health of service. --- ### EcsDeployment <a name="EcsDeployment" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment"></a> A CodeDeploy Deployment for a Amazon ECS service DeploymentGroup. An EcsDeploymentGroup must only have 1 EcsDeployment. This limit is enforced by removing the scope and id from the constructor. The scope will always be set to the EcsDeploymentGroup and the id will always be set to the string 'Deployment' to force an error if mulitiple EcsDeployment constructs are created for a single EcsDeploymentGroup. #### Initializers <a name="Initializers" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.Initializer"></a> ```typescript import { EcsDeployment } from '@cdklabs/cdk-ecs-codedeploy' new EcsDeployment(props: EcsDeploymentProps) ``` | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment.Initializer.parameter.props">props</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeploymentProps">EcsDeploymentProps</a></code> | *No description.* | --- ##### `props`<sup>Required</sup> <a name="props" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.Initializer.parameter.props"></a> - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeploymentProps">EcsDeploymentProps</a> --- #### Methods <a name="Methods" id="Methods"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment.toString">toString</a></code> | Returns a string representation of this construct. | --- ##### `toString` <a name="toString" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.toString"></a> ```typescript public toString(): string ``` Returns a string representation of this construct. #### Static Functions <a name="Static Functions" id="Static Functions"></a> | **Name** | **Description** | | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. | --- ##### ~~`isConstruct`~~ <a name="isConstruct" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.isConstruct"></a> ```typescript import { EcsDeployment } from '@cdklabs/cdk-ecs-codedeploy' EcsDeployment.isConstruct(x: any) ``` Checks if `x` is a construct. ###### `x`<sup>Required</sup> <a name="x" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.isConstruct.parameter.x"></a> - *Type:* any Any object. --- #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.EcsDeployment.property.deploymentId">deploymentId</a></code> | <code>string</code> | The id of the deployment that was created. | --- ##### `node`<sup>Required</sup> <a name="node" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.property.node"></a> ```typescript public readonly node: Node; ``` - *Type:* constructs.Node The tree node. --- ##### `deploymentId`<sup>Required</sup> <a name="deploymentId" id="@cdklabs/cdk-ecs-codedeploy.EcsDeployment.property.deploymentId"></a> ```typescript public readonly deploymentId: string; ``` - *Type:* string The id of the deployment that was created. --- ## Structs <a name="Structs" id="Structs"></a> ### ApiCanaryProps <a name="ApiCanaryProps" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps"></a> #### Initializer <a name="Initializer" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.Initializer"></a> ```typescript import { ApiCanaryProps } from '@cdklabs/cdk-ecs-codedeploy' const apiCanaryProps: ApiCanaryProps = { ... } ``` #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.baseUrl">baseUrl</a></code> | <code>string</code> | The base URL to use for tests. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.artifactsBucketLocation">artifactsBucketLocation</a></code> | <code>aws-cdk-lib.aws_synthetics.ArtifactsBucketLocation</code> | The s3 location that stores the data of the canary runs. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.canaryName">canaryName</a></code> | <code>string</code> | The name of the canary. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.durationAlarmThreshold">durationAlarmThreshold</a></code> | <code>aws-cdk-lib.Duration</code> | The threshold for triggering an alarm on the test duration. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.failureRetentionPeriod">failureRetentionPeriod</a></code> | <code>aws-cdk-lib.Duration</code> | How many days should failed runs be retained. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.role">role</a></code> | <code>aws-cdk-lib.aws_iam.IRole</code> | Canary execution role. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.schedule">schedule</a></code> | <code>aws-cdk-lib.aws_synthetics.Schedule</code> | Specify the schedule for how often the canary runs. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.securityGroups">securityGroups</a></code> | <code>aws-cdk-lib.aws_ec2.ISecurityGroup[]</code> | The list of security groups to associate with the canary's network interfaces. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.startAfterCreation">startAfterCreation</a></code> | <code>boolean</code> | Whether or not the canary should start after creation. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.steps">steps</a></code> | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep">ApiTestStep</a>[]</code> | The steps to perform in the synthetic test. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.successRetentionPeriod">successRetentionPeriod</a></code> | <code>aws-cdk-lib.Duration</code> | How many days should successful runs be retained. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.threadCount">threadCount</a></code> | <code>number</code> | The number of threads to run concurrently for the synthetic test. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.timeToLive">timeToLive</a></code> | <code>aws-cdk-lib.Duration</code> | How long the canary will be in a 'RUNNING' state. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.vpc">vpc</a></code> | <code>aws-cdk-lib.aws_ec2.IVpc</code> | The VPC where this canary is run. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.vpcSubnets">vpcSubnets</a></code> | <code>aws-cdk-lib.aws_ec2.SubnetSelection</code> | Where to place the network interfaces within the VPC. | --- ##### `baseUrl`<sup>Required</sup> <a name="baseUrl" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.baseUrl"></a> ```typescript public readonly baseUrl: string; ``` - *Type:* string The base URL to use for tests. --- ##### `artifactsBucketLocation`<sup>Optional</sup> <a name="artifactsBucketLocation" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.artifactsBucketLocation"></a> ```typescript public readonly artifactsBucketLocation: ArtifactsBucketLocation; ``` - *Type:* aws-cdk-lib.aws_synthetics.ArtifactsBucketLocation - *Default:* A new s3 bucket will be created without a prefix. The s3 location that stores the data of the canary runs. --- ##### `canaryName`<sup>Optional</sup> <a name="canaryName" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.canaryName"></a> ```typescript public readonly canaryName: string; ``` - *Type:* string - *Default:* A unique name will be generated from the construct ID The name of the canary. Be sure to give it a descriptive name that distinguishes it from other canaries in your account. Do not include secrets or proprietary information in your canary name. The canary name makes up part of the canary ARN, which is included in outbound calls over the internet. > [https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/servicelens_canaries_security.html](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/servicelens_canaries_security.html) --- ##### `durationAlarmThreshold`<sup>Optional</sup> <a name="durationAlarmThreshold" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.durationAlarmThreshold"></a> ```typescript public readonly durationAlarmThreshold: Duration; ``` - *Type:* aws-cdk-lib.Duration - *Default:* no alarm is created for duration The threshold for triggering an alarm on the test duration. --- ##### `failureRetentionPeriod`<sup>Optional</sup> <a name="failureRetentionPeriod" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.failureRetentionPeriod"></a> ```typescript public readonly failureRetentionPeriod: Duration; ``` - *Type:* aws-cdk-lib.Duration - *Default:* Duration.days(31) How many days should failed runs be retained. --- ##### `role`<sup>Optional</sup> <a name="role" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.role"></a> ```typescript public readonly role: IRole; ``` - *Type:* aws-cdk-lib.aws_iam.IRole - *Default:* A unique role will be generated for this canary. You can add permissions to roles by calling 'addToRolePolicy'. Canary execution role. This is the role that will be assumed by the canary upon execution. It controls the permissions that the canary will have. The role must be assumable by the AWS Lambda service principal. If not supplied, a role will be created with all the required permissions. If you provide a Role, you must add the required permissions. > [required permissions: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-synthetics-canary.html#cfn-synthetics-canary-executionrolearn](required permissions: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-synthetics-canary.html#cfn-synthetics-canary-executionrolearn) --- ##### `schedule`<sup>Optional</sup> <a name="schedule" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.schedule"></a> ```typescript public readonly schedule: Schedule; ``` - *Type:* aws-cdk-lib.aws_synthetics.Schedule - *Default:* 'rate(5 minutes)' Specify the schedule for how often the canary runs. For example, if you set `schedule` to `rate(10 minutes)`, then the canary will run every 10 minutes. You can set the schedule with `Schedule.rate(Duration)` (recommended) or you can specify an expression using `Schedule.expression()`. --- ##### `securityGroups`<sup>Optional</sup> <a name="securityGroups" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.securityGroups"></a> ```typescript public readonly securityGroups: ISecurityGroup[]; ``` - *Type:* aws-cdk-lib.aws_ec2.ISecurityGroup[] - *Default:* If the canary is placed within a VPC and a security group is not specified a dedicated security group will be created for this canary. The list of security groups to associate with the canary's network interfaces. You must provide `vpc` when using this prop. --- ##### `startAfterCreation`<sup>Optional</sup> <a name="startAfterCreation" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.startAfterCreation"></a> ```typescript public readonly startAfterCreation: boolean; ``` - *Type:* boolean - *Default:* true Whether or not the canary should start after creation. --- ##### `steps`<sup>Optional</sup> <a name="steps" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.steps"></a> ```typescript public readonly steps: ApiTestStep[]; ``` - *Type:* <a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep">ApiTestStep</a>[] The steps to perform in the synthetic test. --- ##### `successRetentionPeriod`<sup>Optional</sup> <a name="successRetentionPeriod" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.successRetentionPeriod"></a> ```typescript public readonly successRetentionPeriod: Duration; ``` - *Type:* aws-cdk-lib.Duration - *Default:* Duration.days(31) How many days should successful runs be retained. --- ##### `threadCount`<sup>Optional</sup> <a name="threadCount" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.threadCount"></a> ```typescript public readonly threadCount: number; ``` - *Type:* number - *Default:* 20 The number of threads to run concurrently for the synthetic test. --- ##### `timeToLive`<sup>Optional</sup> <a name="timeToLive" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.timeToLive"></a> ```typescript public readonly timeToLive: Duration; ``` - *Type:* aws-cdk-lib.Duration - *Default:* no limit How long the canary will be in a 'RUNNING' state. For example, if you set `timeToLive` to be 1 hour and `schedule` to be `rate(10 minutes)`, your canary will run at 10 minute intervals for an hour, for a total of 6 times. --- ##### `vpc`<sup>Optional</sup> <a name="vpc" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.vpc"></a> ```typescript public readonly vpc: IVpc; ``` - *Type:* aws-cdk-lib.aws_ec2.IVpc - *Default:* Not in VPC The VPC where this canary is run. Specify this if the canary needs to access resources in a VPC. --- ##### `vpcSubnets`<sup>Optional</sup> <a name="vpcSubnets" id="@cdklabs/cdk-ecs-codedeploy.ApiCanaryProps.property.vpcSubnets"></a> ```typescript public readonly vpcSubnets: SubnetSelection; ``` - *Type:* aws-cdk-lib.aws_ec2.SubnetSelection - *Default:* the Vpc default strategy if not specified Where to place the network interfaces within the VPC. You must provide `vpc` when using this prop. --- ### ApiTestStep <a name="ApiTestStep" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep"></a> #### Initializer <a name="Initializer" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.Initializer"></a> ```typescript import { ApiTestStep } from '@cdklabs/cdk-ecs-codedeploy' const apiTestStep: ApiTestStep = { ... } ``` #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.name">name</a></code> | <code>string</code> | Name of test. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.path">path</a></code> | <code>string</code> | Path of HTTP request, relative to baseUrl. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.body">body</a></code> | <code>string</code> | Optional body to include in HTTP request. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.expectedValue">expectedValue</a></code> | <code>any</code> | Expected value to compare against the jmesPath. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.headers">headers</a></code> | <code>{[ key: string ]: string}</code> | Optional headers to include in HTTP request. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.jmesPath">jmesPath</a></code> | <code>string</code> | JMESPath to apply against the response from the HTTP request and compare against expected value. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.method">method</a></code> | <code>string</code> | Optional method to for HTTP request. | --- ##### `name`<sup>Required</sup> <a name="name" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.name"></a> ```typescript public readonly name: string; ``` - *Type:* string Name of test. --- ##### `path`<sup>Required</sup> <a name="path" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.path"></a> ```typescript public readonly path: string; ``` - *Type:* string Path of HTTP request, relative to baseUrl. --- ##### `body`<sup>Optional</sup> <a name="body" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.body"></a> ```typescript public readonly body: string; ``` - *Type:* string - *Default:* no body included. Optional body to include in HTTP request. --- ##### `expectedValue`<sup>Optional</sup> <a name="expectedValue" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.expectedValue"></a> ```typescript public readonly expectedValue: any; ``` - *Type:* any - *Default:* undefined Expected value to compare against the jmesPath. --- ##### `headers`<sup>Optional</sup> <a name="headers" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.headers"></a> ```typescript public readonly headers: {[ key: string ]: string}; ``` - *Type:* {[ key: string ]: string} - *Default:* no headers included. Optional headers to include in HTTP request. --- ##### `jmesPath`<sup>Optional</sup> <a name="jmesPath" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.jmesPath"></a> ```typescript public readonly jmesPath: string; ``` - *Type:* string - *Default:* no JMESPath assertion will be performed. JMESPath to apply against the response from the HTTP request and compare against expected value. --- ##### `method`<sup>Optional</sup> <a name="method" id="@cdklabs/cdk-ecs-codedeploy.ApiTestStep.property.method"></a> ```typescript public readonly method: string; ``` - *Type:* string - *Default:* GET Optional method to for HTTP request. --- ### ApplicationLoadBalancedCodeDeployedFargateServiceProps <a name="ApplicationLoadBalancedCodeDeployedFargateServiceProps" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps"></a> The properties for the ApplicationLoadBalancedCodeDeployedFargateService service. #### Initializer <a name="Initializer" id="@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.Initializer"></a> ```typescript import { ApplicationLoadBalancedCodeDeployedFargateServiceProps } from '@cdklabs/cdk-ecs-codedeploy' const applicationLoadBalancedCodeDeployedFargateServiceProps: ApplicationLoadBalancedCodeDeployedFargateServiceProps = { ... } ``` #### Properties <a name="Properties" id="Properties"></a> | **Name** | **Type** | **Description** | | --- | --- | --- | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.capacityProviderStrategies">capacityProviderStrategies</a></code> | <code>aws-cdk-lib.aws_ecs.CapacityProviderStrategy[]</code> | A list of Capacity Provider strategies used to place a service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.certificate">certificate</a></code> | <code>aws-cdk-lib.aws_certificatemanager.ICertificate</code> | Certificate Manager certificate to associate with the load balancer. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.circuitBreaker">circuitBreaker</a></code> | <code>aws-cdk-lib.aws_ecs.DeploymentCircuitBreaker</code> | Whether to enable the deployment circuit breaker. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.cloudMapOptions">cloudMapOptions</a></code> | <code>aws-cdk-lib.aws_ecs.CloudMapOptions</code> | The options for configuring an Amazon ECS service to use service discovery. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.cluster">cluster</a></code> | <code>aws-cdk-lib.aws_ecs.ICluster</code> | The name of the cluster that hosts the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.deploymentController">deploymentController</a></code> | <code>aws-cdk-lib.aws_ecs.DeploymentController</code> | Specifies which deployment controller to use for the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.desiredCount">desiredCount</a></code> | <code>number</code> | The desired number of instantiations of the task definition to keep running on the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.domainName">domainName</a></code> | <code>string</code> | The domain name for the service, e.g. "api.example.com.". | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.domainZone">domainZone</a></code> | <code>aws-cdk-lib.aws_route53.IHostedZone</code> | The Route53 hosted zone for the domain, e.g. "example.com.". | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.enableECSManagedTags">enableECSManagedTags</a></code> | <code>boolean</code> | Specifies whether to enable Amazon ECS managed tags for the tasks within the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.enableExecuteCommand">enableExecuteCommand</a></code> | <code>boolean</code> | Whether ECS Exec should be enabled. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.healthCheckGracePeriod">healthCheckGracePeriod</a></code> | <code>aws-cdk-lib.Duration</code> | The period of time, in seconds, that the Amazon ECS service scheduler ignores unhealthy Elastic Load Balancing target health checks after a task has first started. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.idleTimeout">idleTimeout</a></code> | <code>aws-cdk-lib.Duration</code> | The load balancer idle timeout, in seconds. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.listenerPort">listenerPort</a></code> | <code>number</code> | Listener port of the application load balancer that will serve traffic to the service. | | <code><a href="#@cdklabs/cdk-ecs-codedeploy.ApplicationLoadBalancedCodeDeployedFargateServiceProps.property.loadBalancer">loadBalancer</a></code> | <code>aws-cdk-lib.a