-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aws-cdk-lib/aws-ecs-patterns: setting maxHealthyPercent incorrectly causes stack to fail to deploy #26158
Comments
I can't find anywhere in the documentation what the acceptable range of values is - but it can certainly be above 100 according to the docs. It does appear to only accept whole numbers though, so we could check for that, and clarify in our docs that a whole number is required |
…validation (#26193) Setting `maxHealthyPercent` to a non-integer value was not raising synth-time errors, but was generating invalid CFN templates. This fix adds validation for both `maxHealthyPercent` and `minHealthyPercent`. Closes #26158. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
…validation (aws#26193) Setting `maxHealthyPercent` to a non-integer value was not raising synth-time errors, but was generating invalid CFN templates. This fix adds validation for both `maxHealthyPercent` and `minHealthyPercent`. Closes aws#26158. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Describe the bug
Setting the
maxHealthyPercent
on anApplicationLoadBalancedFargateService
to an invalid value does not raise a synth-time error, but it generates invalid CFN templates.Expected Behavior
Setting the
maxHealthyPercent
on anApplicationLoadBalancedFargateService
to a value such as 0.5 should trigger a compile-time error.Current Behavior
The invalid config is synthed without raising any warnings and results in the stack failing to apply.
Reproduction Steps
Setting the
maxHealthyPercent
on anApplicationLoadBalancedFargateService
to a value such as 0.5.Possible Solution
Throw an exception at synth-time if
maxHealthyPercent
is not a whole integer between 0 and 100 inclusive.Additional Information/Context
No response
CDK CLI Version
2.79.1
Framework Version
No response
Node.js Version
19.1.0
OS
Linux
Language
Typescript
Language Version
No response
Other information
No response
The text was updated successfully, but these errors were encountered: