ARCHOS 525 BLUEPRINT · /d/dgm_hotel-reservation
Hotel Reservation System (hold, pay, confirm with a Saga)
12 COMPONENTS · 15 FLOWS · UPDATED 2026-11-21
GITHUB README / PR PREVIEW CARD
[](https://archos.sageideas.dev/d/dgm_hotel-reservation) *Interactive architecture diagram powered by [ArchOS Studio](https://archos.sageideas.dev/d/dgm_hotel-reservation)*
NOTION / DOCS / CONFLUENCE EMBED
<iframe src="https://archos.sageideas.dev/embed/dgm_hotel-reservation" width="100%" height="580" style="border:1px solid rgba(240,236,225,0.14);border-radius:6px;" loading="lazy" title="Hotel Reservation System (hold, pay, confirm with a Saga) — Interactive in ArchOS"></iframe>
PORTABLE MERMAID SPEC (GITHUB / NOTION / RFC)
flowchart LR
guest_0[("Web Client")]
pay_1[("Payment provider")]
idp_2[("Identity provider (IdP)")]
gw_3["API gateway"]
svc_4["Reservation service"]
hs_5[("Session store")]
db_6[("Reservation database")]
queue_7[("Message queue")]
notif_8[("Notification service")]
tsdb_9[("Time-series database (TSDB)")]
alerting_10[("Alerting")]
capacity_11["Capacity Estimate"]
guest_0 -->|"1. Calls with JWT · HTTPS"| gw_3
gw_3 -->|"2. Starts booking · HTTP/2"| svc_4
svc_4 -->|"3. Holds / releases nights · TCP"| hs_5
hs_5 -->|"4. Returns hold · TCP"| svc_4
svc_4 -->|"5. Charges / refunds card · HTTPS"| pay_1
pay_1 -->|"6. Returns result · HTTPS"| svc_4
svc_4 -->|"7. Confirms booking · SQL"| db_6
db_6 -->|"8. Returns outcome · SQL"| svc_4
svc_4 -->|"9a. Returns booking · HTTP/2"| gw_3
svc_4 -.->|"9b. Relays event from outbox · TCP"| queue_7
queue_7 -.->|"10b. Delivers · TCP"| notif_8
gw_3 -->|"10a. Relays booking · HTTPS"| guest_0
idp_2 -->|"Publishes keys (JWKS) · HTTPS"| gw_3
svc_4 -->|"Exports (OTLP) · OTLP"| tsdb_9
tsdb_9 -->|"Feeds Alerting · HTTP"| alerting_10COMPONENT STACK (11)
- Web ClientSTATEFULSearches and books rooms from an untrusted network
- Payment providerSTATEFULCharges and refunds cards; honours idempotency keys
- Identity provider (IdP)STATEFULIssues the JWT; publishes its signing keys
- API gatewaySTATELESSChecks the JWT, then forwards the booking
- Reservation serviceSTATELESSRuns the Saga: hold, charge, confirm or release
- Session storeSTATEFULHolds rooms 15 minutes; the key expires
- Reservation databaseSTATEFULNights with a version; bookings by booking id
- Message queueSTATEFULHolds events for the notifier
- Notification serviceSTATEFULEmails the guest; drops repeated events by id
- Time-series database (TSDB)STATEFULStores conflicts, expiries, refunds and latency
- AlertingSTATEFULPages on-call when refunds or conflicts spike
REQUEST & DATA FLOW (15)
- Web Client → API gateway (Calls with JWT)[HTTPS]
- API gateway → Reservation service (Starts booking)[HTTP/2]
- Reservation service → Session store (Holds / releases nights)[TCP]
- Session store → Reservation service (Returns hold)[TCP]
- Reservation service → Payment provider (Charges / refunds card)[HTTPS]
- Payment provider → Reservation service (Returns result)[HTTPS]
- Reservation service → Reservation database (Confirms booking)[SQL]
- Reservation database → Reservation service (Returns outcome)[SQL]
- Reservation service → API gateway (Returns booking)[HTTP/2]
- Reservation service → Message queue (Relays event from outbox)[TCP]
- Message queue → Notification service (Delivers)[TCP]
- API gateway → Web Client (Relays booking)[HTTPS]
- Identity provider (IdP) → API gateway (Publishes keys (JWKS))[HTTPS]
- Reservation service → Time-series database (TSDB) (Exports (OTLP))[OTLP]