-
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
feat(stepfunctions-tasks): add cpu and memory parameters to EcsRunTask #30140
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request
. Additionally, if clarification is needed add Clarification Request
to a comment.
e56c7d9
to
6c74ef8
Compare
This PR has been in the CHANGES REQUESTED state for 3 weeks, and looks abandoned. To keep this PR from being closed, please continue work on it. If not, it will automatically be closed in a week. |
3f2da80
to
2431e4c
Compare
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
This PR has been in the MERGE CONFLICTS state for 3 weeks, and looks abandoned. To keep this PR from being closed, please continue work on it. If not, it will automatically be closed in a week. |
Review please! |
Hi This PR has been pending for community review for a while. Please consider posting it on the #contributing channel in cdk.dev. Community members will be on the lookout there as well for possible reviews. Check How to get your P2 PR community reviewed for more details. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR! I left some comments but otherwise LGTM.
packages/aws-cdk-lib/aws-stepfunctions-tasks/lib/ecs/run-task.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To the maintaners: can you confirm the decision made here? Or let us know if there are other options 🙏
Thanks @kackyt for submitting the PR, want to be double sure that we're not adding the functionality that can already be achieved with the help of container override. Could you help in providing a specific use case of ECS run task where this was not working for you. If you've a code snippet that you're using that would help too. |
This is useful when you want to allocate resources flexibly according to the data set used in EcsTask, or when you want to increase memory when retrying from errors such as OOM.Furthermore, in Fargate Task, this parameter is required to specify the size. We cannot change the size of the Fargate with container override. |
Thanks @kackyt, checked the differences with the deployment, i'm not sure i completely agree with statement that it is not supported in Fargate Cluster nor i found any documentation stating that, I see overrides getting populated in the state machine definition for both EC2 and Fargate, let me know if i'm missing something here. Here is the code snippet:
That being said, adding these values help to override the cpu and memory set at task definition level which i don't think exist today, and would review PR for that requirement. Task override:
|
packages/aws-cdk-lib/aws-stepfunctions-tasks/lib/ecs/run-task.ts
Outdated
Show resolved
Hide resolved
packages/aws-cdk-lib/aws-stepfunctions-tasks/lib/ecs/run-task.ts
Outdated
Show resolved
Hide resolved
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Comments on closed issues and PRs are hard for our team to see. |
Issue # (if applicable)
Closes #30027 .
Reason for this change
As described in the issue.
Description of changes
Add cpu and memoryMiB property to EcsRunTaskProps.
Description of how you validated changes
Add unit tests.
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license