Business Context
The competitor research
Two real, current WMS/WFM products were surveyed for this domain:
Manhattan Active Labor Management — "Labor Monitoring: manage actual performance against standards in real time" plus "Time Tracking."
Blue Yonder Workforce & Labor Management — "align labor to demand with real-time operational signals," plus "Continuous Improvement: monitor performance trends over time and utilize employee report cards to align people to corporate goals and systematically coach preferred methods."
Both converge on the same underlying capability: an engineered labor standard (an expected time-per-task-type — "a PICK should take 45s") paired with actual-vs-standard performance scoring ("this associate's last PICK took 52s — 87% of standard"). Both vendors treat it as a distinct product capability, not a sub-feature bolted onto shift/schedule planning — the same shape of evidence this fleet's other DDD decisions have used to justify a dedicated model rather than bolting a new concept onto an adjacent one.
Why neither existing sibling context is the right home
workforce-management owns "who is on shift, on which PATH, at what
rate." Its own design explicitly stops at the path boundary and never
links an associate to a specific task — scoring an individual task
completion would mean crossing a boundary that context's own
documentation treats as load-bearing.
fulfillment-execution owns Task/Station lifecycle. It publishes WHO
completed a task and HOW LONG it took as an enrichment on its existing
TaskCompleted event, but it has zero concept of a "standard" to measure
that duration against. Adding one there would be scope creep into a
domain neither Task nor Station has any business modeling, violating that
repo's own "stops at Task/Station only" design discipline.
A new bounded context is the correct home: it inherits neither sibling's boundary promise, so it is free to model "here is the standard, here is the actual, here is the score" without either context compromising its own boundary to host it. See the source repository's ADR-0002 for the full decision record.
What an engineered standard is, and why it must freeze at completion time
The problem this context solves has two halves:
- Define the standard. Someone — an industrial engineer, a time-study — decides a PICK should take 45 seconds. That number needs a home, a revision history (standards genuinely change as processes improve), and a way to answer "what was the standard active when THIS task completed," not "what is the standard right now."
- Score the actual against it. Every completed task, consumed from
fulfillment-execution'sTaskCompletedevent, gets anEfficiencyPct—100 * standard / actual— frozen forever at ingestion time.
The frozen-at-completion-time rule exists because Kafka delivery is
at-least-once and can reorder or replay. Consider a PICK standard that
is 45s throughout August, then re-timed to 40s starting September 1st. A
TaskCompleted for an August task could be consumed — or re-consumed
after a redelivery — in September, after the revision has already
landed. If EfficiencyPct were computed by looking up "whatever standard
is active right now" at read/consume time, that August task's score would
silently change to reflect a standard that did not even exist when the
work happened — rewriting history that was accurate under the standard
genuinely in force in August.
Instead, this context resolves the active LaborStandard for a
TaskType as of the event's CompletedAt timestamp — exactly once,
at ingestion — and stores the resolved value redundantly on the
TaskPerformance row as StandardSecondsAtCompletion. Neither that
field nor the derived EfficiencyPct is ever recomputed later. A
TaskPerformance row read in a year gives the same answer it gave the
day it was recorded, no matter how many times the standard has since been
revised. See ADR 0004
in the source repository for the full decision record.
This also means EfficiencyPct never divides by zero: an unmeasurable
completion (ActualSeconds<=0 — no claim-timestamp existed to compute a
duration from) or a TaskType with no standard yet defined
(StandardSecondsAtCompletion<=0) both yield a clean null, a real
business fact, not a fabricated number.
The same standard also plans the labour
An engineered standard is also what a planning context needs to say how many
labour hours a day's demand requires. Rather than let warehouse-planning
declare a second set of numbers that would drift from the ones scoring uses,
this context publishes LaborStandardDefined and LaborStandardRevised on its
integration topic warehouse.labor-performance.events, where
warehouse-planning keeps a local copy
(ADR 0038).
A standard also gains an optional site_code: engineered times differ between
buildings, and an empty site code still means every site. A consumer that knows
the site prefers the site-specific standard; scoring is unchanged — this
context does not attribute a completed task to a site, so
RecordTaskPerformance keeps scoring against the site-less standard.
A pure observer, not a decision-maker
Both Manhattan and Blue Yonder go further than pure visibility — Manhattan's "Pay for Performance" ties compensation to these scores, and both vendors offer gamification and coaching workflows. This context deliberately stops short:
This context surfaces the number. A human or another system decides what to do with it.
That discipline is mirrored directly from workforce-management's own
"flags a gap, does not decide" design philosophy for PathUnderstaffed.
A below-standard associate is still allowed to claim tasks in
fulfillment-execution — this is visibility, not enforcement, and it
extends all the way through the newer additions to this context:
CoachingFlag(closing Blue Yonder's "systematically coach preferred methods" gap) is a signal a human reads. It never gates or blocks a below-standard associate's ability to claim tasks, never triggers a notification or automated workflow, and never feeds automatic pay/bonus calculation.MeanActualSeconds(closing the loop forworkforce-management'sProposePathPlan, which previously trusted a caller-suppliedplannedRateverbatim with no connection to reality) is a real measured rate a caller can choose to read — it never makesplannedRatemandatory-derived, and it never requires a synchronous call for every plan proposal.- Idle-gap / utilization (ADR 0014) extends the same observer
posture to the gaps between tasks: this context derives an
associate's idle wait from data it already has (the previous
completion and this claim's implied timestamp), publishes it
additively on
TaskPerformanceRecorded, and exposes windowedGetUtilizationread models over REST and MCP. It never decides whether idleness is a problem worth acting on —workforce-managementandwarehouse-ops-agentare the two downstream consumers that turn the measurement into a staffing signal and an advisory correlation, respectively; this context only ever measures and surfaces the number.
Automatic pay/bonus calculation, gamification, and coaching workflows are
explicitly deferred out of scope. This context does not talk to payroll,
HR, or scheduling systems, and it never calls fulfillment-execution,
workforce-management or any other sibling context over REST or MCP
(even a standard's travel component is caller-supplied rather than looked
up in facility-layout, ADR 0015) — see
Bounded Context Canvas for the full
strategic picture.