Ubiquitous Language
The definitions below are pulled directly from
internal/domain/processpath/process_path.go,
internal/domain/cptschedule/cpt_schedule.go,
internal/domain/processflow/process_flow.go,
internal/domain/cptschedule/events.go,
internal/domain/shared/shared.go,
internal/domain/shared/eligibility.go and
internal/domain/shared/events.go — not reinvented for this page. Part of
the DDD artifact pack.
Glossary → code
| Term | Code identifier | Kind | Wire name (REST / Kafka) | Note |
|---|---|---|---|---|
| Process Path | processpath.ProcessPath | Aggregate root | processPathResponse DTO / ProcessPathData | |
| Path Id | shared.PathId | Identity (string type) | pathId / path_id | Same identity as fulfillment-execution task.Type, wes-work-planning WorkPool.PathId, workforce-management PathPlan.PathId. |
| Match Prefix | ProcessPath.matchPrefix (MatchPrefix()) | Attribute | matchPrefix / match_prefix | |
| Direct | ProcessPath.direct (Direct()) | Attribute | direct / direct | Omitted from the Kafka payload when false (omitempty). |
| Capability | shared.Capability | Value (string type) | requiredCapabilities[] / required_capabilities[] | The domain term is required capabilities; the type is the single Capability. |
| Destination Location Role | shared.DestinationLocationRole | Value (closed string enum) | destinationLocationRole / destination_location_role | Constants DestinationLocationRoleUnset, ...Drop, ...WorkCenter, ...Shipping. |
| Cycle Time p95 | ProcessPath.cycleTimeP95 (time.Duration) | Attribute | cycleTimeP95 / cycle_time_p95 | Go duration string on both wires (2h0m0s). |
| Eligibility | shared.Eligibility | Value object | eligibility / eligibility | Fields maxUnitsPerLine, requiredProductAttributes, excludedProductAttributes, nonSortable. |
| Status | processpath.Status | Enumeration | status | StatusActive = "ACTIVE", StatusDeactivated = "DEACTIVATED". Not carried on Kafka — the event type conveys it. |
| Define / Revise / Deactivate | processpath.Define, (*ProcessPath).Revise, (*ProcessPath).Deactivate | Factory / commands | POST, PUT, DELETE /process-paths… | Use cases usecases.DefinePath, RevisePath, DeactivatePath. |
| CPT Schedule | cptschedule.CPTSchedule | Aggregate root | cptScheduleResponse DTO / CPTScheduleData | One per site. |
| Site Id | shared.SiteId | Identity (string type) | siteId / site_id | facility-layout vocabulary, never validated against it. |
| Cutoff | cptschedule.Cutoff | Entity (local identity cptId) | cutoffs[] | Built by cptschedule.NewCutoff. |
| CPT Id | Cutoff.cptId | Local identity | cptId / cpt_id | Unique within a schedule. |
| Local Time | Cutoff.localTime | Attribute | localTime / local_time | Strict HH:MM 24-hour. |
| Day of Week | cptschedule.Weekday | Enumeration | daysOfWeek[] / days_of_week[] | Mon..Sun. |
| Ship Method | Cutoff.shipMethod | Attribute | shipMethod / ship_method | Free-form label. |
| Eligible Path Ids | Cutoff.eligiblePathIds | Reference by id | eligiblePathIds / eligible_path_ids | Must name Active paths (use-case check). |
| Cutoff Snapshot | cptschedule.CutoffSnapshot | Event payload part | CutoffData | Code-only name; the domain says "cutoff". |
| Process Path Created / Updated / Deactivated | shared.ProcessPathCreated, shared.ProcessPathUpdated, shared.ProcessPathDeactivated | Domain events | com.warehouse.wes.process-path-management.processpath.<Name> | |
| CPT Schedule Changed | cptschedule.CPTScheduleChanged | Domain event | com.warehouse.wes.process-path-management.cptschedule.CPTScheduleChanged | Full snapshot, raised on define AND revise. |
| Process Flow | processflow.ProcessFlow | Aggregate root | processFlowDTO (MCP) / ProcessFlowData | The ordered stages a workload passes through; identity processflow.FlowId (flowId / flow_id); status ACTIVE/RETIRED; version is published (ADR 0042). A ProcessPath is one stage of work, a flow says which stage follows which. |
| Stage | processflow.Stage | Value object | stages[] (pathId, processType / path_id, process_type) | Built by processflow.NewStage; a path appears at most once per flow. |
| Process Type | processflow.ProcessType | Enumeration | processType / process_type | PICK, REBIN, PACK, SLAM, DISPATCH, ARRIVAL, RELOCATE, REPLENISH. |
| Define / Revise / Retire (flow) | processflow.Define, (*ProcessFlow).Revise, (*ProcessFlow).Retire | Factory / commands | PUT /process-flows/{flowId} (define and revise), DELETE /process-flows/{flowId} (retire) | Use cases usecases.DefineProcessFlow (define AND revise), RetireProcessFlow. |
| Process Flow Defined / Revised / Retired | processflow.ProcessFlowDefined, processflow.ProcessFlowRevised, processflow.ProcessFlowRetired | Domain events | com.warehouse.wes.process-path-management.processflow.<Name> | Full state with version; ProcessFlowRevised is also the start-up republish. |
| Catalogue Growth report | report.CatalogueReport, report.Row | Read model | GET /reports/catalogue-growth | Analytics side, not part of the OLTP model. |
Terms whose code name differs: "required capabilities" →
shared.Capability slice; "deactivate" is a soft delete exposed as HTTP
DELETE; "cutoff" in events is CutoffSnapshot / CutoffData;
"revise a CPT schedule" has no separate use case — DefineCPTSchedule
both defines and revises.
ProcessPath
ProcessPathimplements the operator-configurable definition of one process path (its canonical identity, the path_id-family match rule downstream consumers use, and the capabilities a station/associate must hold to work it).
The aggregate root. Identity (PathId) is immutable once constructed;
MatchPrefix, RequiredCapabilities, CycleTimeP95 and Eligibility may
be revised while Active via Revise; Direct and
DestinationLocationRole are immutable (they describe structural facts
about the path's routing shape, not operational parameters operators
tune).
This aggregate replaces what was, before this service existed, a static
YAML file (warehouse-infra/config/process-paths/sortable-fc.yaml)
loaded once at boot by three other services.
PathId
PathIdis the canonical identity of a process path (e.g."PICK","PACK","REBIN","SLAM"). It is the SAME identityfulfillment-execution'stask.Type,wes-work-planning'sWorkPool.PathId, andworkforce-management'sPathPlan.PathIdall reference — this service is the one place that identity is DEFINED, not just consumed.
Kept as a plain string type (not an enum) because the valid set is
operator-configurable, not compiled in. The families an environment must
define are declared in catalogue/paths.json and applied through the API
(see Process-path catalogue).
RELOCATE is the path that carries slot-plan moves (a SKU moved between
bins, planned by wes-work-planning from an approved slotting plan) as
floor work. Capability relocate; its intake is SLOT_RELOCATION only, so
the path is never chosen for order fulfilment
(ADR 0033,
ADR 0034).
DISPATCH is the path that carries the dispatch leg of an inter-warehouse
stock transfer. Capability dispatch; its intake is STOCK_TRANSFER only.
The path id is the fulfillment-execution task type, so it is DISPATCH, not
TRANSFER_DISPATCH
(ADR 0035).
REPLENISH is the path that carries pick-face top-ups (a replenishment
planned by wes-work-planning from a pick-face-replenishment request).
Capability replenish; its intake is REPLENISHMENT only, the one demand
source that may route work onto it
(ADR 0036).
Capability
Capabilityis a named qualification a station/associate must hold to work a process path (e.g."pick","pack","hazmat") — the exact same vocabularyworkforce-management'sCertificationandfulfillment-execution'sStation.Capabilityalready use.
This service does not invent a new capability vocabulary; it is the authoritative SOURCE for which capabilities a given path requires.
Intake and DemandSource
Intakeis the set of demand sources allowed to route work onto a path (ADR 0034). ADemandSourceis one ofCUSTOMER_ORDER(order-management order lines),STOCK_TRANSFER(network-inventory-planning transfer legs, via WES),SLOT_RELOCATION(approved slot-plan moves, via WES),REPLENISHMENT(pick-face top-ups, via WES; ADR 0036) orINVENTORY_CONTROL(amnesty, damage, problem solve).
A set: distinct values, canonical order, unknown or repeated values rejected
(shared.ErrInvalidIntake). The empty set is valid and means the path is
reached only by an explicit path id from an upstream stage (PACK, REBIN,
SLAM). Routing policy, not identity: revisable while Active. Not to be
confused with eligibility, which says what a unit of work must look like
to be routed to the path, not who may route it there.
MatchPrefix
The lower-case prefix downstream consumers match a caller-supplied id
against: id == matchPrefix OR id starts with matchPrefix + "-" —
never a bare substring match without the separator (a hypothetical
"picking-station" must not match "pick"). Validated lower-case at
construction time (ErrMatchPrefixNotLowercase) — not lower-cased for the
caller — so persisted data is exactly what was validated.
Direct
A structural fact about the path's routing shape (reserved for a future
multi-hop topology, not a day-to-day operational parameter). Immutable
once set at Define time — never revisable via Revise.
DestinationLocationRole
An optional declaration of which facility-layout LocationRole a
completed task on this path is destined for: Drop, WorkCenter or
Shipping, or unset (the zero value). Declarative routing intent only —
this service never calls facility-layout to validate it; the closed value
set is kept in sync by convention
(shared.ErrInvalidDestinationLocationRole for an unknown value).
Immutable once set at Define time. See
ADR 0009.
CycleTimeP95
The operator-declared p95 end-to-end cycle time from release into the path to manifest (ADR 0010) — a declared standard, not a measured value.
Required and strictly positive (ErrInvalidCycleTime otherwise),
revisable while Active. See
ADR 0010.
Eligibility
A value object declaring the rules a unit of work must satisfy to be
routed to a path: maxUnitsPerLine (unset means unbounded; 1 declares a
singles path), requiredProductAttributes, excludedProductAttributes,
and nonSortable. Every field is optional and the zero value is fully
permissive. Compared with Eligibility.Equal for no-op detection.
CPTSchedule, Cutoff, SiteId
A site-scoped, recurring Critical Pull Time (CPT) schedule. A CPT is a property of a departure, not of a path — several paths feed the same truck, and a slow path simply cannot make the later ones — so the schedule is modelled once per site rather than duplicated on every path.
The second aggregate root, identified by SiteId. It holds an IANA
timezone and one or more Cutoffs, each with a cptId (unique within
the schedule), a localTime (HH:MM), daysOfWeek (Mon..Sun), a
shipMethod, and the eligiblePathIds that can make it. Revised
wholesale, never partially.
ProcessFlow, Stage, ProcessType
The ordered sequence of process-path stages a workload passes through. A
ProcessPathnames one stage of work (PICK,PACK,REBIN,SLAM); which stage feeds which is the flow's job, not the path's. (ADR 0042)
The third aggregate root, identified by FlowId. It holds a name, one or
more ordered Stages (each a pathId naming an Active path and a
processType from the closed set PICK, REBIN, PACK, SLAM,
DISPATCH, ARRIVAL, RELOCATE, REPLENISH), a status
(ACTIVE/RETIRED) and a version that starts at 1 and grows by one per
accepted change. A path appears at most once per flow. Revised wholesale,
retired rather than deleted; a retired flow cannot be revised.
Status (Active / Deactivated)
Statusis the activation lifecycle of a ProcessPath. There is no "draft" state — a path is live the instant it is defined.
Two values: ACTIVE and DEACTIVATED. Deactivation is a one-way,
idempotent transition — see the
Aggregate Design Canvas for the full
lifecycle.