[Batch] [Feature]: Set alarm for Batch job congestion
- Dominant language
- Shell
- Stars
- 5.4k
- Forks
- 334
- PR merge metrics
- No merged PRs in 30d
Description
### Community Note
* Please vote on this issue by adding a 👍 [reaction](https://blog.github.com/2016-03-10-add-reactions-to-pull-requests-issues-and-comments/) to the original issue to help the community and maintainers prioritize this request
* Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
* If you are interested in working on this issue or have submitted a pull request, please leave a comment
**Tell us about your request**
[Ticket raised on behalf of Customers]
Customers have been requesting for a way to set up alarms to monitor Batch jobs based on status and send notification when the number exceeds a certain threshold.
For example:
There are have been occasions when customers have jobs stuck for an extended period in STARTING state, holding resources in the underlying ECS nodes, and resulting in significant unnecessary spend. Through Cloudwatch alarms it will easier to avoid situation like these.
**Which service(s) is this request for?**
Batch, ECS
**Are you currently working around this issue?**
Right now the only way to get notifications for batch events based on the number of jobs in a particular state is through a custom solution to send this alarm.
A solution would be to periodically run a Lambda function that checks the number of jobs in a state, then using CloudWatch/SNS to notify you when this number exceeds a configured value.
Contributor guide
Research direction
Start by reviewing the requested Batch and ECS behavior and the proposed Lambda, CloudWatch, and SNS workaround. Define the supported job states, threshold configuration, and notification behavior; the work is done when customers can receive an alarm when jobs in a selected state exceed the configured threshold.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws
- Domain
- cloud, observability
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100