feat(batch): jobStateTimeLimitActions property added#30158
feat(batch): jobStateTimeLimitActions property added#30158mergify[bot] merged 24 commits intoaws:mainfrom
Conversation
| * The action to take when a job is at the head of the job queue in the specified state | ||
| * for the specified period of time. | ||
| */ | ||
| readonly action: JobStateTimeLimitActionsAction; |
There was a problem hiding this comment.
It may be better to make action optional and set the default value to JobStateTimeLimitActionsAction.CANCEL, since that is the only value we can configure at the moment.
There was a problem hiding this comment.
Thank you for your comment.
I think your suggestion is better.
I have changed action to be optional and set its default value to JobStateTimeLimitActionsAction.CANCEL.
| /** | ||
| * The state of the job needed to trigger the action. | ||
| */ | ||
| readonly state: JobStateTimeLimitActionsState; |
There was a problem hiding this comment.
This is similar comment above, it may be better to make state optional and set default value to JobStateTimeLimitActionsState.RUNNABLE.
There was a problem hiding this comment.
Thanks.
I have changed state to be optional and set its default value to JobStateTimeLimitActionsState.RUNNABLE.
|
I am not a reviewer, but I have provided some comments for your reference. |
go-to-k
left a comment
There was a problem hiding this comment.
Thank you for this PR.
Sorry for the many comments, but I commented as much as I could see.
I may make additional comments if anything else comes up.
| * The reason to log for the action being taken. | ||
| * @see https://docs.aws.amazon.com/batch/latest/userguide/troubleshooting.html#job_stuck_in_runnable | ||
| */ | ||
| export enum JobStateTimeLimitActionsReason { |
There was a problem hiding this comment.
Shouldn't we add the MISCONFIGURATION:SERVICE_ROLE_PERMISSIONS?
There was a problem hiding this comment.
There was a problem hiding this comment.
Could you also add a new test for the case where the array is empty?
There was a problem hiding this comment.
I added a test case for an empty array.
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
Co-authored-by: k.goto <24818752+go-to-k@users.noreply.github.com>
go-to-k
left a comment
There was a problem hiding this comment.
Thanks for the changes, LGTM.
|
@GavinZZ |
|
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. If you need help, please open a new issue that references this one. |


Issue # (if applicable)
Closes #30142 .
Reason for this change
Missing property in the L2 Construct.
Description of changes
Add jobStateTimeLimitActions property to the JobQueue Construct.
Description of how you validated changes
Add unit tests and integ tests.
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license