warehouse-systems fleet · executive briefing

network-fulfillment

Lets an outside retail network order from our building without overpromising
seven capabilitys8 events out · 5 in35 recorded decisions

This project is a domain-driven design study. It is not associated with, endorsed by or affiliated with any company, and it uses no company's code, data, logos or trademarks. All names, figures and examples are illustrative or synthetic. · November 2026

the short version · read this if nothing else

Network fulfillment promises the network only what the floor can actually ship before the next cutoff

1

Every network order gets one clear answer inside the 24-hour window, or is rejected in time.

2

Advertised stock is capped by what pick paths can move before cutoff, not just shelf stock.

3

Network terms and PII stop at the adapters, so the warehouse keeps its own language.

The ask

Verify the live loops end to end against the retail-network counterpart before any real network order flows.

why it exists

Never promise the network more than the floor can keep

Sells the building's fulfillment capability to an external retail network honestly: it polls network demand, translates network product ids to SKUs, holds an order in order-management, and acknowledges or rejects within the network's 24-hour fill-or-kill SLA. Its one genuinely new domain concept is throughput-constrained advertised availability…

Today

It polls network demand, holds matching orders locally, and answers each one within the network's 24-hour fill-or-kill window.

The catch

The live network adapter exists but nothing has run against a real network, and the vocabulary-leak guard is checked by humans.

what it does

Six capabilities answer the network fast and honestly

Inbound network demand

Network orders are polled, translated to our SKUs, held locally, then answered in full.

24-hour deadline sweep

Overdue orders are rejected automatically and their held local orders cancelled.

Throughput-capped offers

We advertise the smaller of stock on hand and what pick paths can move by cutoff.

Supply loop

Declares the node profile and feeds our offers to the network in live mode.

Inbound loop

Polls seller shipments into inbound ASNs and returns receipts to the network.

Shipment confirmation

Confirms shipments back to the network, with a REST fallback endpoint.

who it talks to

Three contexts feed it, one context builds on what it publishes

LISTENS TO · 4 EVENT TYPESIS HEARD BY · 1 CONTEXTSinbound-receiving2outbound-shipping1process-path-management1exception-management2networkfulfillmentbadge = event types on that edge · derived from the CloudEvents types each repo declares
the shared language

Network orders and capability offers are the two big ideas

THE LANGUAGEOF THE DOMAINNetworkOrderCapabilityOfferAnti-corruption boundarySweep/reconcile use cases…
REST10 operations over 10 paths: api :8080…
MCPMCP server (cmd/mcp, :8090, Streamable HTTP…
A2AA2A agent (cmd/a2a, :8093): 2 read skills…
how it is built

A translation layer keeps the network's language at the door

DRIVERS · INBOUNDOUTBOUND · ADAPTERSREST API :808010 operations over 10 paths…MCP tools :8090MCP server (cmd/mcp, :8090…Kafka consumer · 5 eventsCPTScheduleChangedPathCapacityChangedDOMAIN CORENetworkOrderCapabilityOfferAnti-corruption boundarySweep/reconcile use…PostgreSQLPostgres onlyKafka producer · 8 eventsNetworkOrderReceivedNetworkOrderSubmittedTransactional outboxrelay · DLQ on x-dlq-*commands inevents inevents outstorage / infra
event traffic · CloudEvents 1.0 on Kafka

Seven order facts go out, each with an analytics twin

CONSUMED · BY SOURCE · 6PUBLISHED · BY ENTITY · 8inbound-receiving 2unattributed 2outbound-shipping 1process-path-management 18 domain eventsUpdatedwork-planning PathCapacityC…outbound-shipping…CartonDiscrepancyRaisedReceiptClosedown analytics topic via…NetworkOrderReceivedNetworkOrderSubmittedNetworkOrderAcknowledgedNetworkOrderRejectedNetworkOrderShipmentConfirmedAcknowledgementDeadlineAtRisk
how we know it is healthy

Inbound status shows unanswered and overdue orders at a glance

OpenTelemetry: OTLP/gRPC traces + metrics (30 s push) from netfulfil, mcp and reports (projector: Go-runtime metrics only), otelchi HTTP metrics (ADR 0020), plus a Prometheus GET /metrics on netfulfil only…

What we watch

  • inbound-status endpoint exposes networkMode, poller counters and unanswered/overdue counts
  • Custom instruments: network_fulfillment.node_profile.declarations/revision and orphaned_holds.swept…
  • Outbox relay attempt cap OUTBOX_MAX_ATTEMPTS default 20 (ADR 0021); boot resilience documented in docs/operations-notes.md

What stops a bad change

  • make check-fast before done; check-all full gate (90% coverage on domain+application, arch-test, bdd)
  • CI jobs: lint, guide-lint, complexity, file-length, test, bdd, integration, pinned-contracts, api-lint, mutation-fast, vuln, docs-api-drift…
by the numbers

35 decisions, 14 migrations and 20 BDD feature files

35
Architecture decisions
#9 of 45 in the fleet
14
DB migrations
#4 of 45 in the fleet
20
BDD feature files
#8 of 45 in the fleet
8
Events published
#14 of 45 in the fleet

Ranked against all 45 briefed repositories (dot = one repository, highest on the left).

One-command workflows (make)

checkcheck-allcheck-fasttestcoveragebddintegrationarch-testmutationmutation-fullvulnguide-lintharness-test
competitive position

Against the market leaders, this is where we trail

GapNetwork & Capacity Planning vs Blue Yonder (multi-echelon planning), Manhattan (future inventory)

Owns the anti-corruption layer toward the external retail network.

Where we match or lead

  • Deterministic, explainable transfer proposals (score breakdown, policy version…
  • Transfer saga with allocation replies driving ALLOCATED / UNFULFILLABLE
  • Anti-corruption layer and capability offers toward an external retail network
  • Effective-capacity and bottleneck detection per process path with shortage detection

Gaps to close

  • High Adapter is stub-only; NETWORK_MODE=live refuses to boot
  • Medium Vocabulary-leak guard is human-only, not automated
  • Low No BDD feature files yet (fleet parity gap)

Leader capabilities are vendor-published; gaps reflect repo docs reviewed in November 2026.

what comes next

Next: verify the live loops, close the shipment gaps, tighten mutation

NOW1Close the shipmentconfirmation gapsShipment confirmationgaps (README 'Not builtyet'): noPackageManifested-driventrigger, no real packagecount (label requestsone package), and anetwork FAILURE of aconfirmation is only …NEXT2Settle GTINmastership beforecatalogueCatalogue packaging toproduct-master isdeliberately not built:GTIN mastershipsemantics unsettled (ADR0028 §5)NEXT3Verify the liveloops end to endVerify the live loopsend to end: nothing ranagainst a real network,node-topology oroffer-availability (ADR0027 'Not verified');the counterpart is thefleet's ownretail-network (ADR …LATER4Raise mutationcoverage to the99/99 standardRaise the mutationthresholds:.gremlins.yaml setsefficacy 99 /mutant-coverage 92(fleet standard 99/99),measured beforecapabilityoffer…LATER5Keepvocabulary-leakreviews humanKeep vocabulary-leakchecking human — arch-gocannot catch networkfield names entering thedomain
what could go wrong · and what we do about it

Our biggest risk is that nothing has run against a real network

No real network has been tested; only the fleet's stand-in

Every REST, MCP and A2A endpoint is unauthenticated by decision (AGENTS.md hard rule 2: no ship-to PII reaches this context)

→

Verify the live loops end to end against the retail-network counterpart.

The vocabulary-leak guard is human-only

The live adapter is validated only against the fleet's own retail-network stub/fakes…

→

Kept as an explicit review rule, since arch-go cannot catch network field names.

Boot needs cluster-specific retries; a 200 is no commitment

Human-only guard against vocabulary leaks (purchaseOrderNumber/ASIN) — the most important boundary rule is not automated

→

A boot-retry budget and a startup probe absorb the first-dial reset; reconcile sweeps settle submissions.

No auth on REST, MCP or A2A, by decision

Boot depends on cluster-specific retry behavior (Istio first-dial reset, ADR 0011)…

→

No mitigation on the roadmap yet: this one needs an owner.

the decision we need

Verify the live loops end to end against the retail-network counterpart before any real network order flows.

WHAT ISIt polls network demand, holdsmatching orders locally, and answerseach one within the network's24-hour fill-or-kill window.THE CATCHThe live network adapter exists butnothing has run against a realnetwork, and the vocabulary-leakguard is checked by humans.WHAT COULD BEReal network orders flowing in,shipment confirmation working end toend, and mutation gates at the fleetstandard.
Why it matters

Network fulfillment promises the network only what the floor can actually ship before the next cutoff

appendix · for the engineers in the room

The fine print: how it is put together

StyleHexagonal (ports & adapters) enforced by arch-go; Conformist upstream, ACL downstream; GitFlow (develop promotes to main); Postgres and Kafka are the only runtime (ADR 0025)
Layoutcmd/{netfulfil,netfulfil-projector,netfulfil-reports,mcp,a2a}; internal/{domain/{networkorder,capabilityoffer,shared}, application/{contract,ports,usecases}…
StoragePostgres only (DATABASE_URL and KAFKA_BROKERS mandatory, no in-memory mode, ADR 0025): 14 OLTP *.up.sql migrations (init, outbox, submitted state…
Testingmake check-all (90% coverage gate on domain+application, arch-test incl. TestA2AAdapterStaysReadOnly, bdd 20 feature files); testcontainers Postgres+Kafka integration (make integration)…
REST10 operations over 10 paths: api :8080 — GET /healthz, /readyz, /metrics, /inbound-status, /network-orders (keyset-paged)…
Gochisegmentio/kafka-go + CloudEvents…pgxpool + golang-migratePostgresOpenTelemetrymodelcontextprotocol/go-sdka2a-goarch-go + godog + testcontainers…Helm chart on kind cluster behind…web/ MFE remote