Context Map
Built on develop (merged 2026-11-08) in IQVO/dock-scheduling, released at v0.1.3 (first release v0.1.0 on 2026-11-09; applied to the k3s cluster on 2026-11-10 at v0.1.2 in a reduced footprint, and the image pinned to the v0.1.3 commit a1a029c in warehouse-infra since 2026-11-16, checked 2026-12-02): dock-scheduling runs its API only (it relays inline); yard-management runs its API and relay. The MCP server (18 tools on develop 096db0a, 14 in v0.1.3) is registered in warehouse-infra but switched off until the cluster has room; the A2A agent (two skills) is built on develop (2026-12-02), not released and not deployed (the chart carries it off by default and warehouse-infra has no a2a block); the analytics projectors, report services and sweeps are registered but switched off, so the KPI reports of yard-management ADR 0011 are released, not yet served. The page still derives from yard/model/model.yaml; where the as-built service differs, the model and this page say so (see the as-built notes).
Following ddd-crew Context Mapping. This is dock-scheduling's slice of the yard context map: every relationship it has, with the upstream (U) and downstream (D) side, the pattern and the channel. Abbreviations: OHS = Open Host Service, PL = Published Language, CF = Conformist, C/S = Customer/Supplier.
Derived from: model.yaml → contexts[dock-scheduling].inbound,
.publishes[*].consumers, .consumes; the matching inbound rows of
contexts[yard-management]; fleet_changes.
Legend: arrows point from upstream to downstream. Solid = events or
commands; dotted = synchronous query.
yard-management and inbound-receiving appear twice because they are on
both sides: they feed this context and they consume from it. People are
rounded boxes. Patterns on the edges to warehouse-planning,
inbound-receiving, exception-management and outbound-shipping are this pack's reading; the
model names no pattern for them.
Omitted: Kafka and Postgres as infrastructure; the analytics-only events
(DockAppointmentCheckedIn, DockAppointmentCompleted, DockAppointmentAtRisk,
DoorOperatingHoursDeclared), which have no named consumer; the
changes to warehouse-console and warehouse-floor-client (they are
clients of the REST routes, listed in fleet_changes). Separate Ways (no edge at all): the retail network
(retailnetwork.* topics and services); the model's hard_boundary rules
out any yard context consuming a retailnetwork.* topic or calling a
retail-network service.
Relationships
| Neighbour | Direction | Pattern | Channel | Messages | Why this pattern |
|---|---|---|---|---|---|
yard-management (Supporting) | Upstream for yard facts; downstream for appointments (mutual) | Customer/Supplier both ways (the model names it on both inbound rows) | Kafka warehouse.yard-management.events into this context; warehouse.dock-scheduling.events out | In: VisitCheckedIn, VisitRejected, TrailerDocked, TrailerUndocked. Out: DockAppointmentBooked, DockAppointmentRescheduled, DockAppointmentCancelled, DockAppointmentNoShow, DoorClosureScheduled, DoorClosureLifted | The two flows are independent (plan against physical) and neither writes into the other's aggregates. Each side shapes its events for the other and keeps an event-fed local copy; no synchronous call in either direction. |
facility-layout | Upstream | Conformist | Kafka warehouse.facility.events | LocationSlotRegistered, LocationSlotDecommissioned, ZoneRegistered | facility-layout is the registry of slots and zones for every context. Dock slots, dockFlow and the zone to site join are taken as given into DoorView. |
inbound-receiving | Upstream for ASNs; downstream for appointments | Conformist for ASNs; consumer of this context's Booked, Rescheduled, Cancelled and DoorReassigned | Kafka warehouse.inbound-receiving.events in; warehouse.dock-scheduling.events out | In: ASNRegistered, ASNCancelled. Out: DockAppointmentBooked, DockAppointmentRescheduled, DockAppointmentCancelled, DockAppointmentDoorReassigned | ASNs are taken as given into AsnView. The appointment moved to this context (YD-0002): inbound-receiving retired its appointment write routes and keeps an appointments copy fed by this context (its ADR 0019). The legacy import feed (policy LegacyImport, strangler stage A) was removed in dock-scheduling ADR 0011 (stage E of inbound-receiving ADR 0019): this context consumes no dockappointment.* type from inbound-receiving, only the two ASN events. |
process-path-management | Upstream | Conformist | Kafka warehouse.process-path-management.events | CPTScheduleChanged | The CPT schedule is the fleet's own outbound cutoff; it is taken as given into CutoffView. |
| Carrier scheduler (carrier portal) | Upstream (person or carrier system) | OHS on this context's REST | REST POST /appointments, .../reschedules, .../cancellations, .../eta-reports | BookAppointment, RescheduleAppointment, CancelAppointment, ReportEta | Carriers are outside the fleet; the contract is one published REST surface. |
| Dock planner | Upstream (person, console) | UI on this context's REST | REST PUT .../operating-hours, PUT .../settings, POST .../closures, POST .../closures/{closureId}/lifts | DeclareOperatingHours, DeclareCalendarSettings, ScheduleDoorClosure, LiftDoorClosure; also RescheduleAppointment and CancelAppointment on behalf of a carrier (D-5) | Human maintenance of the door calendar. |
| Scheduler (cron) | Upstream (CronJob) | UI on this context's REST | REST POST /no-show-sweeps | MarkNoShow | An idempotent sweep called on a timer. |
warehouse-planning | Downstream | OHS + PL (this pack's reading) | Kafka warehouse.dock-scheduling.events | DockAppointmentBooked, DockAppointmentRescheduled, DockAppointmentCancelled, DockAppointmentNoShow | Inbound labour demand. warehouse-planning reads these events instead of inbound-receiving's (its ADR 0020, merged on develop); they gain site_id and direction. |
exception-management | Downstream | OHS + PL (this pack's reading) | Kafka warehouse.dock-scheduling.events | DockAppointmentNoShow | Opens a problem case per no-show (merged on develop). |
outbound-shipping | Downstream | OHS + PL (this pack's reading) | Kafka warehouse.dock-scheduling.events | DockAppointmentBooked | Ship-confirm context; it also reads the yard's departure facts (outbound-shipping is released as v0.1.0, registered and image-pinned in warehouse-infra develop, PR 205, and applied to k3s on 2026-11-12 at 857edfd, with the consumer group outbound-shipping-dock set, so the edge is live: both ends run). |
warehouse-ops-agent (MCP client) and any AI client | Downstream | OHS / Customer with an ACL (the agent's MCP client adapter) | MCP Streamable HTTP through the Agent Router, /api/mcp/dock-scheduling rewritten to /mcp | This service's cmd/mcp server: 18 tools on develop (8 L1 reads, 2 L2 proposals, 8 L3 writes with initiated_by); the ops agent wires seven of the eight L1 reads (get_appointment, get_carrier, get_dock_calendar, get_door_availability, list_appointments, list_at_risk_appointments, list_carriers) | Wired on develop (checked 2026-12-02 at abc8472, its ADR 0032): DOCK_SCHEDULING_MCP_ENDPOINT builds the client, read by RescheduleOutlook and YardDockBrief (its ADR 0035); unset, both fail open (ErrDockSchedulingNotConfigured). Off in the cluster: helm-values/warehouse-ops-agent.yaml sets no endpoint, and this service's MCP server is off there (mcp.enabled: false in helm-values/dock-scheduling.yaml). The agent never writes over MCP; arrival, door release, calendar changes and the sweep are on no MCP tool. |
warehouse-ops-agent (A2A delegating client) and any agent client | Downstream (delegating a goal) | OHS / Customer: the delegation carries the goal, never facts | A2A JSON-RPC 2.0 through the Agent Router, /api/a2a/dock-scheduling rewritten to / | appointment_options (L1) and book_or_reschedule_appointment (L3; the ops agent only ever sends operation=reschedule) | Built on develop (service ADR 0015, first commit d78d414, 2026-12-02), not in v0.1.3 and not deployed: the chart component is off by default, warehouse-infra has no a2a block, and the agent's DOCK_SCHEDULING_A2A_URL is unset, so its reschedule proposal stays a token-less L2. |
| Any context | Downstream | OHS | REST GET /appointments, GET /appointments/{appointmentId}, GET /doors/{doorCode}/availability, GET /sites/{siteId}/dock-calendar | ListAppointments, GetAppointment, GetDoorAvailability, GetDockCalendar | Read access for tools and diagnostics; no decision path of a sibling depends on it (decisions use events). |
Notes on the patterns
- Mutual Customer/Supplier with
yard-management. The model puts the two contexts in each other's consumer list. The risk is a start-up cycle or a feedback loop; the safeguards named in the model are idempotent consumers (inbox on the CloudEventsid) and version-guarded readers (apply onlyversiongreater than the stored one). - Conformist upstream, Open Host downstream. This context conforms to
facility-layout,inbound-receiving(ASNs) andprocess-path-management, and offers its appointment and closure events as a published language. - No Anti-Corruption Layer. All neighbours are in the same fleet and
share the CloudEvents standard; translation stops at local read models.
The future
transport-visibilitycontext is the first place the model expects an ACL (an ETA feed intoReportEta). - No Shared Kernel.
shared(door code, site id, carrier and SCAC) is a package inside this service (theulcode identifiershared.Carrier), not shared code across contexts. Identifiers such assiteId,doorCodeandasn_numberare values copied from events.