New to Kestra?
Use blueprints to kickstart your first workflows.
Monitor AWS Lambda stream processing latency and IteratorAge with Kestra. Query CloudWatch, file GitHub issues, and alert Slack.
Serverless architectures frequently stream events from Amazon Kinesis Data Streams or DynamoDB Streams into AWS Lambda functions. When incoming event volume exceeds function concurrency, batch processing times out, or unhandled exceptions trigger retries, the Lambda IteratorAge surges, indicating stream processing lag. This blueprint monitors CloudWatch IteratorAge metrics, identifies stream processing delays, files a GitHub incident ticket, and alerts engineering teams via Slack.
periodic_iterator_age_check runs every 15 minutes.probe_iterator_age_metric queries CloudWatch for Maximum IteratorAge.evaluate_stream_lag evaluates if lag exceeds threshold.branch_on_stream_lag logs a GitHub issue and alerts Slack if breached.log_audit_complete logs final outcome.errors block alerts Slack on execution failure.Kestra provides declarative automation connecting CloudWatch metrics, conditional evaluation, and chat notifications in a single auditable flow.
AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY: AWS credentials.GITHUB_TOKEN: GitHub token.SLACK_WEBHOOK: Slack webhook URL.aws_region: Target region.function_name: Lambda function name.iterator_age_ms_threshold: Max age before alerting.target_repository: GitHub repository.outputs.evaluate_stream_lag.value.max_iterator_age_ms: Maximum IteratorAge.outputs.evaluate_stream_lag.value.is_lag_critical: Boolean breach flag.