Skip to main content

Fulfillment Execution

Study project

This documentation site is an educational Domain-Driven Design exercise. It follows real industry-standard patterns and terminology, but it is not a production system and is not affiliated with, endorsed by, or representative of any real-world company.

Fulfillment Execution turns released work into completed physical operations. It owns the task lifecycle for the process paths of the outbound value stream — Pick, Rebin (order consolidation), Pack, and SLAM (Scan, Label, Apply, Manifest) — and nothing else.

It sits between its neighbours in the warehouse-systems platform:

  • Upstream: wes-work-planning, the conductor, decides what work to release and when. Every unit it releases arrives here as a WorkReleased integration event and becomes a Task in this service's pool.
  • Downstream (live): wes-work-planning (completion feedback), labor-performance and inventory-storage consume TaskCompleted, order-management consumes TaskCPTMissed and PackageManifested, and network-inventory-planning consumes the transfer facts, all on warehouse.fulfillment.events. workforce-management reads installed station capacity over REST and warehouse-ops-agent uses the MCP server (Integration contracts).
  • Downstream (strategic): WCS / equipment (conveyors, print-and-apply labellers, check-weighers) would execute the physical steps. That edge is modelled as a deliberately empty port and is not wired — see Context Map.

The one design rule that shapes everything​

Pull, not push. A station claims the next task — claimNext(stationId, capabilities). The system selects work, not workers. There is deliberately no assign(task, station) operation anywhere in this codebase.

Every other decision here follows from that rule. Because the system never names a station in advance, a claim has to be at-most-once (two stations must never end up walking to the same tote), and because a claiming station is a physical human or robot that can drop a scanner, walk away, or lose network, an unconfirmed claim must return to the pool rather than vanish. That is what the lease is for.

Read the reasoning in full on Why pull, not push, and the two architecture decisions that encode it: ADR-0002 and ADR-0003.

What it owns, and what it deliberately does not​

OwnsDoes not ownWho does
The Task pool for Pick / Rebin / Pack / SLAMDeciding what work to release and at what ratewes-work-planning
Pull dispatch (claimNext) and lease lifecycleWhich associate stands at which station this shiftworkforce-management
The Station capability set used to filter claimable workStock truth, reservations, bin-accurate locationinventory-storage
The Package aggregate: seal + SLAM weigh-checkWhether a coded location exists and is legalfacility-layout
Queue depth as a read-model projectionDriving PLCs, motors and sensorsWCS (external, generic subdomain)

The boundary with workforce-management is the sharpest one and is deliberate on both sides: Workforce Management stops at the process-path boundary — it plans headcount per path and never links an associate to an individual task. Dispatch of individual tasks to a claiming station belongs here. The two contexts change at completely different cadences (shifts versus seconds), and keeping them apart is what lets dispatch policy evolve without touching workforce planning.

Where to go next​

Disclaimer

This project is a domain-driven design study. It is not associated with, endorsed by or affiliated with any company, and it uses no company's code, data, logos or trademarks. All names, figures and examples are illustrative or synthetic.