New to Kestra?
Use blueprints to kickstart your first workflows.
Enforce contract validation, retry backoffs, and incident escalation on Camunda 8 service tasks with Kestra.
In Camunda 8 (Zeebe), distributed business processes rely on external job workers to execute Service Tasks. When an external worker crashes or encounters an unhandled exception without explicitly notifying the Zeebe gateway, the job lock simply expires. Camunda re-delivers the locked job indefinitely without decrementing retries, resulting in a silent zombie loop where no incident is ever raised in Camunda Operate.
This blueprint implements a production-grade Camunda 8 Job Worker and Resilience Gate. It activates service task jobs in real time, validates incoming payload contracts, completes successful tasks with enriched execution variables, applies graduated retry backoffs on transient errors, and explicitly fails invalid jobs with zero retries so operators receive instant incident visibility.
camunda_job_stream (io.kestra.plugin.camunda.Trigger) acts as an external Zeebe job worker, activating jobs for the specified job_type and acquiring an execution lock for lock_timeout.validate_payload_contract (io.kestra.plugin.core.debug.Return) verifies that the job's variables fulfill the required business contract (order_id, customer_id, and amount > 0).route_by_contract_evaluation (io.kestra.plugin.core.flow.If) evaluates the contract result:complete_service_task (io.kestra.plugin.camunda.CompleteJob) to report success back to Zeebe with merged variables (fulfillment_status, processed_at), allowing the BPMN token to advance.fail_job_permanent_invalid_schema (io.kestra.plugin.camunda.FailJob) with retries: 0. This stops wasteful re-polling and forces Camunda to immediately raise an Incident in Camunda Operate, while alerting Slack.log_worker_audit (io.kestra.plugin.core.log.Log) logs an immutable record of the job key, process instance key, and outcome.errors block catches unexpected runtime errors and executes fail_job_transient_error (io.kestra.plugin.camunda.FailJob), decrementing retries (retries: trigger.retries - 1) and applying retryBackoff: PT30S so the job cools down before re-activation.Building external workers as standalone microservices requires writing boilerplate gRPC polling loops, heartbeat handlers, retry state trackers, and error notification hooks. With Kestra, Camunda service tasks become first-class declarative workflows with native secret management, visual execution logs, and automated incident escalation.
job_type (default process-order).SLACK_WEBHOOK_URL: Slack incoming webhook URL used for incident notifications and unhandled worker failures.CAMUNDA_CLIENT_ID and CAMUNDA_CLIENT_SECRET.SLACK_WEBHOOK_URL in your Kestra namespace secrets.docker run -d --name zeebe -p 26500:26500 -p 8080:8080 camunda/zeebe:latestprocess-order.{"order_id": "ORD-1234", "customer_id": "CUST-987", "amount": 250.00}triggers.camunda_job_stream and verify the job completes and the process advances.then block before calling CompleteJob.io.kestra.plugin.camunda.PublishMessage to correlate messages with other waiting BPMN catch events.