New to Kestra?
Use blueprints to kickstart your first workflows.
Audit AMQP 1.0 broker dead-letter queues, verify synthetic canary delivery, classify health status, and alert Slack on poison message backlog breaches.
Enterprise messaging backbones running ISO-standard AMQP 1.0 brokers, such as Apache ActiveMQ Artemis, RabbitMQ 4.x, Azure Service Bus, or Apache Qpid, frequently encounter poison messages caused by unexpected serialization shifts, downstream consumer bugs, or schema drift. When unhandled, failing messages route into dead-letter queues (DLQs) where they silently accumulate, consuming broker storage, exhausting memory quotas, and masking recurring application outages.
This blueprint provides an automated Day 2 operations sentinel for AMQP 1.0 brokers. On a scheduled interval, it delivers a synthetic canary message to verify broker link creation and acceptance, samples accumulated dead-letter messages without message destruction, classifies cluster health across five operational tiers, and dispatches real-time Slack alerts before buffer limits cause broker degradation.
periodic_schedule trigger invokes the flow on a 4-hour cadence with explicit parameter bindings, shipped in a disabled state for initial validation.probe_canary_delivery (io.kestra.plugin.amqp.Amqp1Publish) publishes a synthetic JSON heartbeat payload carrying the execution ID and timestamp to canary_address, validating that the broker opens links and returns delivery acceptance.probe_dlq_backlog (io.kestra.plugin.amqp.Amqp1Consume) drains up to sample_limit dead-letter records from dlq_address within bounded maxDuration and pollDuration windows, writing the raw payload stream to Kestra internal storage.classify_broker_posture (io.kestra.plugin.core.debug.Return) evaluates canary delivery counts and consumed DLQ message volume using Pebble logic to produce an unambiguous status token: BROKER_UNREACHABLE, CANARY_DELIVERY_FAILED, DLQ_BACKLOG_BREACH, DLQ_WARNING, or HEALTHY.route_posture_action (io.kestra.plugin.core.flow.Switch) routes downstream actions: critical backlog breaches and delivery failures dispatch actionable alerts to Slack, minor warnings log diagnostic advice, and clean runs confirm stability.audit_sentinel_run (io.kestra.plugin.core.log.Log) writes an immutable summary entry to the execution logs recording the verdict, DLQ count, and published canary metrics.errors handler catches unhandled transport failures or authentication timeouts, dispatching an incident notice to Slack.Scripting broker health checks with custom Python or Bash daemons introduces unmanaged cron jobs, unmasked credential exposure, and fragmented logging. Kestra provides native AMQP 1.0 tasks built directly on Apache Qpid Proton-J2, enterprise secret governance, declarative scheduling, execution auditability, and turnkey Slack alerting without requiring sidecar monitoring daemons or custom consumer agents.
orders.dlq) and a designated canary test address (e.g. sentinel.canary).AMQP_USERNAME: Authentication username for the AMQP 1.0 broker connection.AMQP_PASSWORD: Authentication password or SAS token for the AMQP 1.0 broker connection.SLACK_WEBHOOK_URL: Incoming webhook URL for the destination Slack channel.AMQP_USERNAME, AMQP_PASSWORD, and SLACK_WEBHOOK_URL in your Kestra namespace secrets.docker run -d --name artemis-sentinel \
-p 5672:5672 -p 8161:8161 \
-e ARTEMIS_USER=artemis \
-e ARTEMIS_PASSWORD=artemis \
apache/activemq-artemis:latest
docker network connect YOUR_KESTRA_NETWORK artemis-sentinel
HEALTHY is classified.periodic_schedule trigger to activate autonomous 4-hour background surveillance.io.kestra.plugin.amqp.Amqp1Publish task to replay quarantined messages back to the primary intake queue once downstream defects are resolved.io.kestra.plugin.serdes.avro or JSON Schema validation to automatically quarantine messages failing contract compatibility.io.kestra.plugin.pagerduty for tier-1 on-call paging during sustained broker degradations.