Skip to main content

EventStorming

As built

Derived from network/model/model.yaml. This context's service is built; the model carries its as-built contracts, and identifiers (Err... names, routes, CloudEvents types) are the names the service uses.

Process-level boards (flowchart LR, or TB where LR would be too wide) in the ddd-crew EventStorming glossary & cheat sheet notation. Every sticky is a command, aggregate, event, policy, read model or neighbour from model.yaml. Every hotspot is a genuine gap or risk in the model; the table at the end says where each one comes from. The domain-wide board is EventStorming Big Picture.

Legend​

StickyColourMeaning
Commandblue #a5d8ffAn intention, named as in the model's commands
Aggregateyellow #ffec99The aggregate root that decides
Domain Eventorange #ffc078A fact from the model's publishes (or a consumed one)
Policylilac #d0bfff"Whenever X, then Y", from the model's policies
Read Modelgreen #b2f2bbA local, event-fed view from read_models
External Systempink #fcc2d7A neighbouring context or the fleet
Hotspotred #ff8787An open question or risk in the model
Actorpale orange #fff4e6A person (not in the brief's palette; used only for humans)

1. Catalogue and listing set-up​

Derived from: model.yaml → contexts[offer-availability].aggregates[CatalogItem], .aggregates[Listing], .inbound, .publishes.

Omitted: the ErrInvalidItemDimensions and ErrDuplicateListing refusals (see Use Cases) and the storefront's BrowseCatalog query, which changes nothing.

2. Inventory feed application​

Derived from: model.yaml → contexts[offer-availability].aggregates[InventoryFeed], .aggregates[Listing], .policies[FullFeedZeroing], .business_decisions, .publishes; contexts[vendor-connectivity].sync_calls.

Omitted: the FAILED outcome (ErrListingNotOnNode, ErrNegativeAvailability), which raises no event; the stale-line skip (ErrStaleAvailability), which raises no ListingAvailabilityChanged; the vendor's own Vendor API submission upstream of vendor-connectivity.

3. Node-driven suppression​

Derived from: model.yaml → contexts[offer-availability].policies[SuppressOnNodeUnavailable], .read_models[NodeStatusView], .aggregates[Listing], .consumes, .publishes; contexts[node-topology].publishes.

Omitted: NodeRegistered only inserts the node into NodeStatusView; it triggers no command. RestoreListing reads NodeStatusView because it is refused with ErrNodeNotSellable on a node that is not ACTIVE.

Hotspots and where they come from​

HotspotWhat is openWhere it comes from in model.yaml
H1Resolved (ADR 0002 A11, gap G23): a feed older than the last applied feed for that node ends SUPERSEDED (nothing applied, no event); a stale line is skipped and counted, per-listing ErrStaleAvailability.contexts[offer-availability].business_decisions[1] against .aggregates[InventoryFeed].invariants and .states
H2A full feed for a busy node writes every listing of that node in one atomic apply, while the listing throughput is "high: one update per feed line; bursty". Transaction size and lock time are a risk..aggregates[InventoryFeed].description ("applied atomically"), .aggregates[Listing].throughput_estimate
H3No initial state for Listing: a listing created on a non-ACTIVE node should be SUPPRESSED by the invariant, but CreateListing has no rule, and there is no Availability before the first feed..aggregates[Listing].states, .transitions, .invariants[ErrNodeNotSellable]
H4Resolved (ADR 0002 A4, gap G24): DiscontinueItem suppresses the item's listings with reason DISCONTINUED in the same transaction, and a listing created for a discontinued item starts suppressed..policies[SuppressOnItemDiscontinued]
H5FullFeedZeroing sets availableQty=0, but the vendor declared no basis and no asOf for an omitted listing; "the basis is kept, never re-derived" does not say what a zero carries..policies[FullFeedZeroing], .business_decisions[3], .aggregates[Listing].value_objects
H6ListingSuppressed carries reason, and the policy restores "those suppressed for that reason", but no reason vocabulary is modelled..publishes[ListingSuppressed].data, .policies[SuppressOnNodeUnavailable]