Skip to content

Executors

An executor performs the actual work for a run. Wakeplane dispatches each run based on target.kind. Three executors ship with Wakeplane v0.2.0-beta.1.

target:
kind: http
method: GET
url: https://api.example.com/healthz

The HTTP executor writes a receipt containing response status and a summary of the response body. Timeout and cancellation are handled through context.

target:
kind: shell
command: /usr/local/bin/backup.sh
args:
- "--compress"
- "--destination=/mnt/backups"

The shell executor writes stdout, stderr, and exit code receipts. It uses exec.CommandContext, so timeout or cancellation results in SIGKILL.

target:
kind: workflow
workflow_id: sync.customers
input:
source: crm
dry_run: false

Workflow handlers must be registered explicitly before the service starts:

service, err := app.NewWithOptions(ctx, cfg,
app.WithWorkflowHandler("sync.customers", syncCustomersHandler),
app.WithWorkflowHandler("generate.report", generateReportHandler),
)

Handlers use:

type WorkflowHandler func(ctx context.Context, input map[string]any) (map[string]any, error)

Missing handler registrations fail at dispatch time and follow normal retry/dead-letter behavior.

Receipts for any run are available at:

GET /v1/runs/{id}/receipts
AspectHTTPShellWorkflow
TargetURL + methodCommand + argsRegistered handler by ID
CancellationContext -> HTTP abortContext -> SIGKILLContext -> ctx.Done()
Receipt kindHTTP response summarystdout/stderr/exit codeHandler return value
RegistrationNone neededNone neededMust register explicitly
  • Per-target credential injection
  • Dynamic workflow handler loading
  • gRPC executor
  • Native TLS or auth-aware executor features