Skip to main content

EventStorming

Synced from slotting-optimization

This page is a copy of docs/docs/ddd/eventstorming.md on develop, derived from that repository's code. Edit it there, then re-sync.

A design-level EventStorming of slotting-optimization, using the sticky colours of the ddd-crew EventStorming glossary and cheat sheet: orange domain event, blue command, yellow aggregate, lilac policy, green read model, pink external system, red hotspot, small yellow actor.

Planning flow​

Source: internal/application/usecases/{generate_plan,decide_plan,queries}.go, internal/domain/slotplan/plan.go, internal/domain/planning/planner.go.

Local-copy flow​

Source: internal/application/usecases/consumers.go, internal/adapters/outbound/postgres/read_models.go.

Hotspots​

HotspotWhy it is openWhere it shows
Who executes the moves?decided by ADR 0010 (supersedes ADR 0007): wes-work-planning plans one RELOCATE work unit per move of SlotPlanApproved, fulfillment-execution executes it, inventory-storage records StockRelocated, and this context records the progress per moveresolved; open follow-up: gating new proposals on unfinished execution is out of scope in v1
Demand site id equals facility site code?ForwardSlots joins zones.site_code to the plan's site, which comes from demand site_id; ADR 0003 calls for verifying this against live dataa mismatch makes every SKU NoEligibleSlot
Lexical slot rankinglayout events carry no travel distance, so v1 ranks slots by location code; LocationGeometryUpdated is ignored"best" slot means "first code", not "closest"
No consumer, no Kong route, no chartthe service is built but not wired into the clusterRunbook