alepha@docs:~/docs/reference/providers$
cat ExclusiveProvider.md | pretty
1 min read
Last commit:

#ExclusiveProvider

#Import

typescript
1import { ExclusiveProvider } from "alepha/command";

#Overview

A machine-wide FIFO queue for CLI commands that must not run concurrently.

Claims are reentrant per process and tickets are swept on the owner's pid, never on the age of its heartbeat.

Deliberately not built on alepha/lock: the default MemoryLockProvider is in-process, so two CLI processes would each hold their own and the feature would silently protect nothing. $lock's wait is also a race rather than a queue, and its maxDuration doubles as both the lock TTL and the wait timeout, which breaks on any command that runs longer than it.