Warehouse execution (WES) · Generic domain · EventStorming board
process-path-management
Keeps the warehouse's catalogue of process paths, the order of stages work flows through, and each site's carrier cut-off schedule, and announces every change.
- events published
- 7
- commands
- 8
- policies
- 31
- read models
- 4
- hot spots
- 4
The story in 4 key events
The pivotal events: the few that matter most, in the order they happen.
- Pivotal eventProcess
Path Created - Pivotal eventProcess
Path Updated - Pivotal eventProcess
Path Deactivated - Pivotal eventCPTSchedule
Changed
Listens to (0): contexts whose events this one reacts to
none
Tells (8): contexts that react to its events
The board, row by row
10 rows, in the order the business story happens: the main path first, then how this context reacts to the others, then the clock. Rows are small stories; read each one left to right.
- Event
- Command
- Actor
- Aggregate
- Policy
- Read model
- External system
- Hot spot
- Opportunity
-
Define a new process path
An operator adds a path to the catalogue: its name prefix, the skills it needs, its p95 cycle time and which demand sources may feed it. A path id is never reused, even after retirement.
ActorOperatorCommandDefinePath POST /process-pathsAggregateProcessPath EventProcessPath Created Systemfulfillment-execution PolicyAdds the path to its catalogue copy, so released work for it is accepted and gets its required skillsSystemwes-work- planning PolicyAdds the path to its catalogue copy, so work can be planned onto itSystemworkforce-management PolicyAdds the path to its catalogue copy, so shift plans and assignments can name itSystemorder-management PolicyAdds the path, with its cycle time and eligibility, to the copy it uses to route ordersSystemnetwork-fulfillment PolicyAdds the path's cycle time to the copy it uses for capacity figuresSource: application/usecases/define_path.go · domain/processpath/process_path.go · domain/shared/events.go
-
Revise a process path
An operator changes an active path's prefix, skills, cycle time, eligibility or intake. If nothing actually changed, nothing is announced. The full new definition is sent, never a diff.
ActorOperatorCommandRevisePath PUT /process-paths/{pathId}AggregateProcessPath EventProcessPath Updated Systemfulfillment-execution PolicyReplaces its copy of the path definitionSystemwes-work- planning PolicyReplaces its copy of the path definitionSystemworkforce-management PolicyReplaces its copy of the path definitionSystemorder-management PolicyReplaces its copy, so the next delivery promise uses the new cycle time and eligibilitySystemnetwork-fulfillment PolicyReplaces the cycle time it uses for capacity figuresSource: application/usecases/revise_path.go · domain/processpath/process_path.go
-
Retire a process path
An operator retires a path for good. It is refused while a site's cut-off schedule or an active process flow still uses it, so the operator changes those first.
ActorOperatorRead modelSites whose schedule lists the pathRead modelActive flows that use the pathCommandDeactivatePath DELETE /process-paths/{pathId}AggregateProcessPath EventProcessPath Deactivated Systemfulfillment-execution PolicyRemoves the path from its catalogue copySystemwes-work- planning PolicyRemoves the path from its catalogue copySystemworkforce-management PolicyRemoves the path from its catalogue copySystemorder-management PolicyRemoves the path from its copy, so no order is routed onto itSystemnetwork-fulfillment PolicyRemoves the path from its capacity copySource: application/usecases/deactivate_path.go · domain/processpath/process_path.go · adr/0026-reject-deactivation-of-paths-in-cpt-schedules.md · adr/0028-close-path-cpt-schedule-race-with-row-locks.md · adr/0042-process-flows.md
-
Publish a site's cut-off schedule
An operator sets, or replaces in full, a site's carrier cut-off times. Every path a cut-off lists must be active. An identical schedule changes nothing and announces nothing.
ActorOperatorRead modelActive process pathsCommandDefineCPTSchedule PUT /sites/{siteId}/cpt-scheduleAggregateCPTScheduleEventCPTScheduleChanged Systemorder-management PolicyReplaces the site's cut-off windows it uses to promise delivery timesSystemnetwork-fulfillment PolicyReplaces the site's cut-offs it uses for capacity figuresSystemoutbound-shipping PolicyReplaces its copy of the site's cut-off scheduleSystemdock-scheduling PolicyStores the site's cut-offs as a view; it books no appointment from them yetSource: application/usecases/cpt_schedule.go · domain/cptschedule/cpt_schedule.go · domain/cptschedule/events.go
-
Define or revise a process flow
An operator lays out the order of stages a workload passes through, for example pick, rebin, pack, label. Each stage must be an active path. A request that changes nothing announces nothing.
ActorOperatorRead modelActive process pathsCommandDefineProcess PUT /process-flows/{flowId}Flow AggregateProcessFlow EventProcessFlow Defined EventProcessFlow Revised Systemwarehouse-planning PolicyKeeps a copy of the flow; a path id with an active flow is planned stage by stage, the slowest bindsSource: application/usecases/process_flow.go · domain/processflow/process_flow.go · adr/0042-process-flows.md
-
Retire a process flow
An operator retires a flow. A retired flow cannot be revised again, and its paths may then be retired too.
ActorOperatorCommandRetireProcess DELETE /process-flows/{flowId}Flow AggregateProcessFlow EventProcessFlow Retired Systemwarehouse-planning PolicyStops using the flow and falls back to its own path of that id, if anySource: application/usecases/process_flow.go · domain/processflow/process_flow.go · adr/0042-process-flows.md
-
Replay every active path at start-up
When the service starts, it announces the current definition of each active path again. This way a consumer that rebuilds its catalogue from scratch never misses a path whose first event has aged out.
TimeService startPolicyWhenever the service starts, announce every active path againCommandRepublishCatalogue a background jobAggregateProcessPath EventProcessPath Updated Systemfulfillment-execution PolicyA fresh instance rebuilds its catalogue copy from the replaySystemwes-work- planning PolicyA fresh instance rebuilds its catalogue copy from the replaySystemworkforce-management PolicyA fresh instance rebuilds its catalogue copy from the replaySource: application/usecases/republish_catalogue.go · cmd/pathmgmt/republish.go · adr/0038-republish-catalogue-on-start.md
-
Replay every site's schedule at start-up
In the same start-up pass, the current cut-off schedule of each site is announced again, in full, for the same reason: a fresh consumer must be able to rebuild its copy.
TimeService startPolicyWhenever the service starts, announce every site's schedule againCommandRepublishCatalogue a background jobAggregateCPTScheduleEventCPTScheduleChanged Systemorder-management PolicyA fresh instance rebuilds its cut-off copy from the replaySystemnetwork-fulfillment PolicyA fresh instance rebuilds its cut-off copy from the replaySource: application/usecases/republish_catalogue.go · cmd/pathmgmt/republish.go · adr/0038-republish-catalogue-on-start.md
-
Replay every active flow at start-up
At start-up each active flow is announced again as revised, with its current version. A consumer that is caught up ignores it; a fresh one learns the flow. Retired flows are not replayed.
TimeService startPolicyWhenever the service starts, announce every active flow againCommandRepublishCatalogue a background jobAggregateProcessFlow EventProcessFlow Revised Systemwarehouse-planning PolicyKeeps the flow only if its version is newer than the copy heldSource: application/usecases/republish_catalogue.go · adr/0042-process-flows.md
-
Count catalogue growth for reports
The service reads its own path announcements and keeps a daily tally of paths defined, revised and retired, which feeds the catalogue growth report. It never reads another context's events.
Event · earlierProcessPath Created PolicyWhenever a path is created, revised or retired, add one to that day's tallyCommandApplyProcess started by the policyPath Created Read model · kept up to dateCatalogue growth reportSource: adapters/inbound/kafka/analytics_consumer.go · adr/0007-analytical-data-product.md
Hot spots and opportunities
Open questions and known gaps, each taken from a decision record or a document in the repository, never invented. Opportunities are improvements the documentation already names.
- Hot spotThe site id of a cut-off schedule is never checked. A schedule for an unknown site only shows up later as an unroutable order in order-management.
- Hot spotICQA (inventory control) is deliberately left undecided: it may become a path family, stay in inventory-storage, or call into it.
- Hot spotwes-work-planning and network-inventory-planning do not yet filter on the declared intake values; they route by explicit path id.
- Hot spotHow long announcements are kept is not set here. Consumers rebuild their copy by replaying them all, so the start-up replay is the safety net.
Opportunities
- OpportunityLog compaction would let the broker keep only the latest announcement per path and per site. It is a warehouse-infra change.
- OpportunityIf the fleet gets a real transportation context, the cut-off schedule can move there unchanged. Its place here is provisional.
This board is a reconstruction from the code and documentation of process-path-management at origin/develop, not a workshop output. Roles are the ones the documentation names. How the boards were made.