Skip to content

Commit

Permalink
chore(ecs): remove property override (#12346)
Browse files Browse the repository at this point in the history
chore(ecs): remove the property override for circuit breaker

Fixes: #12345 

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
pahud authored Jan 5, 2021
1 parent b04ed9e commit bf7e92d
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions packages/@aws-cdk/aws-ecs/lib/base/base-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,10 @@ export abstract class BaseService extends Resource
deploymentConfiguration: {
maximumPercent: props.maxHealthyPercent || 200,
minimumHealthyPercent: props.minHealthyPercent === undefined ? 50 : props.minHealthyPercent,
deploymentCircuitBreaker: props.circuitBreaker ? {
enable: true,
rollback: props.circuitBreaker.rollback ?? false,
} : undefined,
},
propagateTags: props.propagateTags === PropagatedTagSource.NONE ? undefined : props.propagateTags,
enableEcsManagedTags: props.enableECSManagedTags === undefined ? false : props.enableECSManagedTags,
Expand All @@ -376,16 +380,6 @@ export abstract class BaseService extends Resource
...additionalProps,
});

if (props.circuitBreaker) {
const deploymentConfiguration = {
DeploymentCircuitBreaker: {
Enable: true,
Rollback: props.circuitBreaker.rollback ?? false,
},
};
// TODO: fix this when this property is available in CfnService
this.resource.addPropertyOverride('DeploymentConfiguration', deploymentConfiguration);
};
if (props.deploymentController?.type === DeploymentControllerType.EXTERNAL) {
Annotations.of(this).addWarning('taskDefinition and launchType are blanked out when using external deployment controller.');
}
Expand Down

0 comments on commit bf7e92d

Please sign in to comment.