Amazon SageMaker and Amazon EventBridge are a great duo
How to automate many little events happening around Amazon SageMaker? By leveraging the ever-awesome Amazon EventBridge
Amazon EventBridge is the event bus service of AWS. You send messages (events) to it and it routes them to other applications or triggers specified AWS services. It provides filtering, transforming, archiving and retrying capabilities too!
SageMaker, like many other AWS services, sends all kinds of events to EventBridge by default, free of cost. Training jobs failing, endpoints completing deployment, models getting approved, pipelines blowing up and more - all these events are automatically sent to EventBridge.
You can then set up rules on EventBridge to push SageMaker events further:
Training failed? Trigger AWS Lambda to send a Slack message
Endpoint deployment completed? Start CodePipeline to redeploy other applications
Pipeline step failed? Save details to SQS for further reprocessing
Model has been approved? Run the next workflow using StepFunctions
And so on.
Additionally, a built-in filtering mechanism allows you to ignore most irrelevant events. You can for example set it up so that it only triggers on Training Jobs with a name prefix of your choice.
You can also send your own, custom events to EventBridge with a single line of code too. EventBridge and custom events are often the heart of serverless applications.
Speaking of serverless - it is a truly serverless service and requires no maintenance whatsoever. It costs little to nothing when used for automation purposes.