Files
commandkit/docs/roadmap/02-dispatch.md

3.0 KiB

CommandKit dispatcher planning record

Status: initial dispatcher implementation complete.

Original planning: 2026-10-06. Reconciled: 2026-10-07.

Authority and current owners

ADR 0001 owns the dispatcher, registry, and typed-input decisions and rationale. The architecture policy owns responsibility boundaries. This document records completion of the initial dispatcher design; the implementation plan preserves its execution history.

The registry, typed inputs, command/group APIs, invocation coordination, and outcomes are implemented. Their exact contracts are owned by Go declarations and GoDoc, rather than the early illustrations formerly maintained here.

API area Current owner
Application construction and registration App/New and App.Register
Typed command declarations, groups, and presence CommandSpec, NewCommand, Group, WithChildren, Supplied
Typed flag and operand bindings Binding helpers
Invocation and result delivery App.Execute, Invocation/Streams, and Outcome
Standard integration registration Configuration suite and PromptKit suite

The consumer guide explains assembly and callback usage. The CLI reference owns syntax and operator behavior; the internal overview owns implemented package mechanics.

Completed design and evidence

The initial work delivered instance registration, composable nested groups, typed handlers and bindings, presence-aware input, capability-based installation, lazy acquisition, and distinct shared/domain outcomes. The original Supplied illustration is now a public declaration; application-specific restore inputs remain consumer examples rather than proposed CommandKit types.

The simple and composed consumers demonstrate the API with configuration inspection and a custom session command. The completed plan records behavioral evidence for routing, ownership conflicts, help, invocation state, cancellation, output failures, and domain outcome preservation.

Completed constructor/binding/outcome design tasks and implementation assignments have been retired from this roadmap. Concurrent dispatch remains outside the initial target under the feature roadmap.

Remaining adoption work

Applications can migrate their routers and repeated standard handlers to the implemented API, update documentation and subprocess consumers for breaking changes, and retain their domain command behavior. Migration is separate from library completion; this record does not claim that the sibling applications have adopted CommandKit. Deferred standard capabilities are tracked in the feature roadmap.