Open nrhtr opened 3 months ago
Hi @nrhtr , thanks for reaching out. I see that you are using a very old version of CDK could you please try running it on CDK 2.137 and see if the issue persists.
Hi @khushail, sorry, I forgot to mention that I also tested with 2.137.0 (build bb90b4c)
with the same result.
Describe the bug
When attempting to update a service which has no capacity provider strategy (i.e. defaulted to EC2 launch type) to have a capacity provider strategy, CDK reports that it will replace the service rather than update-in-place.
This is problematic for two reasons: 1) This will result in downtime, which should not be necessary given that ECS appears to be able to update this in-place with a new deployment. 2) (Perhaps less important, or specific to my use-case) The service replacement doesn't work, and Cloudformation fails with an error that the service "already exists".``
Expected Behavior
I expect the capacity provider strategy would be updated in-place without requiring a service replacement.
Current Behavior
CDK/Cloudformation attempts to recreate the service (with the same name), and fails.
The output from
cdk diff
Fails to deploy:
Reproduction Steps
Possible Solution
No response
Additional Information/Context
I'm currently using this as a workaround:
CDK CLI Version
2.44.0 (build bf32cb1)
Framework Version
No response
Node.js Version
v20.11.1
OS
macOS Sonoma 14.2.1
Language
TypeScript
Language Version
No response
Other information
No response