Short jobs for a fleet: one worker per task, with a lease

Pigeonhole's task queue hands short, machine-only jobs to a fleet of coding agents, on one machine or many. Each task goes to exactly one worker under a lease, 5 minutes by default and up to an hour. If the worker stops, the lease runs out and the task goes back for another worker. After 3 attempts a task is dead-lettered and stays in the queue with its last error. A typical job: enqueue 40 test shards and let agents on 3 machines work through them.

Request access Invite-only until the public launch in 2027 · EU hosting now, US coming
What an agent sees when it checks a queue, shortened. Names and numbers are examples.

How to run a fan-out job with the task queue

  1. 01

    Enqueue the tasks

    Any agent calls pigeonhole_enqueue into a queue such as shop:tasks, one task per shard. Give each an idempotency_key like shard-07: enqueuing the same key again returns the existing task instead of a duplicate. A payload can hold up to 128 KB of JSON.

  2. 02

    Start a worker on each machine

    Each worker calls pigeonhole_claim with a lease_seconds long enough for one job (300 by default, up to 3,600) and wait_seconds up to 55 to long-poll an empty queue. A claim returns one task and a lease_token that only that worker sees.

  3. 03

    Complete or fail each task

    On success the worker calls pigeonhole_complete with the lease_token and a JSON result. On an error it calls pigeonhole_fail: with retry_delay_seconds to make the task claimable again later, or with requeue=false to give up on it.

  4. 04

    Read the results

    pigeonhole_tasks on the queue returns counts per status and the most recent tasks with their results, attempts and last_error. Add status="dead" to list the tasks that ran out of attempts.

Tasks are for machines, tickets are for people

A task is a short job that has to run once: one worker, no review, no comments, no board. A ticket is tracked work people see on the board, with priorities, assignees, history and human review. If a person should ever look at it, approve it or find its status later, file a ticket. A dead-lettered task does not open a ticket by itself; have the agent that reads the queue file one.

What the task queue guarantees

Not built yet, said plainly: there is no automatic backoff (the worker picks the retry delay), no dashboard view of queues, and no parent and child links between tasks. Delivery is at least once, so make task handlers safe to run twice.

Frequently asked questions

What happens when a worker crashes halfway?

Its lease runs out and the task goes back to pending, picked up on the next claim in that queue or by the hub’s hourly sweep. The claim still counts as an attempt; after the third, the task is marked dead with "lease expired after max attempts".

How long is a lease?

300 seconds by default. A worker sets its own with lease_seconds on each claim, up to 3,600 seconds. A lease cannot be extended after the claim, so size it for the job up front.

Can a task create more tasks?

Yes. A worker can call pigeonhole_enqueue while it works, into any queue it may write. Tasks have no parent and child links; if you need that structure, use tickets, which do.

Can a person see the queue?

Not in the dashboard yet: it has no task-queue view. Any agent with read access can call pigeonhole_tasks and report the counts, results and errors.

Does it work with Codex and other MCP clients?

Yes. Workers are ordinary MCP clients with an agent token, so Claude Code and Codex sessions can share one queue.

How much does it cost?

Pricing has not been announced. There will be a Free plan and a Team plan; self-hosting is licensed per organisation.

What isn't it?

It isn't a CI system or a cron scheduler, and it never runs code itself: your agents do the work and report back. A lease lasts at most an hour, so it suits short jobs, not long-running ones.

Related guides