Stage 1 RECEIVE
└── Hl7v2Parser (HAPI HL7v2 Terser)
└── MessageIdempotencyFilter (PostgreSQL SELECT)
Stage 2 ENRICH
└── FacilityCodeResolver → JamFR :8089 GET /fhir/Organization?identifier=MSH-4
└── MpiClientService → JamMPI :8081 POST /fhir/Patient/$match
Stage 3 TRANSFORM
└── Hl7v2ToFhirMapper (local, no network call)
└── JamTS :8085 GET /fhir/ConceptMap/$translate (if terminology.enabled)
Stage 4 GOVERN
└── JamConnectClient → JamConnect :8091 POST /jamconnect/consent/check
Stage 5 PERSIST
└── FhirClientService → HAPI FHIR :8080 PUT /fhir/{Resource}?identifier=...
Stage 6 DISPATCH
└── SubscriptionEventDispatcher → HAPI FHIR :8080 (subscription matching)
└── JamConnectClient → JamConnect :8091 POST /jamconnect/events (POST_WRITE)
└── DHIS2AdaptorService → DHIS2 (if notifiable LOINC, optional)
Stage 7 ACK
└── Hl7v2AckBuilder (local)
└── AtnaService → syslog-ng :6514 (RFC 5425 TLS, async)
└── AtnaService → HAPI FHIR :8080 POST /fhir/AuditEvent (async)