Skip to main content
ARCHOS 525 BLUEPRINT · /d/dgm_resilience-timeouts-breakers-bulkheads-shedding

Orders API (timeouts, circuit breaker, bulkhead and load shedding)

9 COMPONENTS · 10 FLOWS · UPDATED 2026-11-21
GITHUB README / PR PREVIEW CARD
[![Orders API (timeouts, circuit breaker, bulkhead and load shedding) — ArchOS Architecture](https://archos.sageideas.dev/d/dgm_resilience-timeouts-breakers-bulkheads-shedding/opengraph-image)](https://archos.sageideas.dev/d/dgm_resilience-timeouts-breakers-bulkheads-shedding)

*Interactive architecture diagram powered by [ArchOS Studio](https://archos.sageideas.dev/d/dgm_resilience-timeouts-breakers-bulkheads-shedding)*
NOTION / DOCS / CONFLUENCE EMBED
<iframe src="https://archos.sageideas.dev/embed/dgm_resilience-timeouts-breakers-bulkheads-shedding" width="100%" height="580" style="border:1px solid rgba(240,236,225,0.14);border-radius:6px;" loading="lazy" title="Orders API (timeouts, circuit breaker, bulkhead and load shedding) — Interactive in ArchOS"></iframe>
PORTABLE MERMAID SPEC (GITHUB / NOTION / RFC)
flowchart LR
  client_0[("Mobile Client")]
  provider_1[("Payment Provider")]
  gw_2["API gateway"]
  orders_3["Resource server"]
  bulkhead_4["Bulkhead"]
  breaker_5["Circuit breaker"]
  metrics_6[("Time-series database (TSDB)")]
  alerting_7[("Alerting")]
  capacity_8["Capacity Estimate"]
  client_0 -->|"1. Calls with a JWT · HTTPS"| gw_2
  gw_2 -->|"2. Forwards · gRPC"| orders_3
  orders_3 -->|"3a. Takes slot · HTTP/2"| bulkhead_4
  orders_3 -->|"3b. Sheds with 503 · gRPC"| gw_2
  bulkhead_4 -->|"4. Admits within limit · HTTP/2"| breaker_5
  breaker_5 -->|"5a. Calls with key · HTTPS"| provider_1
  breaker_5 -->|"5b. Fails fast when open · HTTP/2"| bulkhead_4
  metrics_6 -->|"Scrapes counters · HTTPS"| orders_3
  metrics_6 -->|"Scrapes state · HTTPS"| breaker_5
  metrics_6 -->|"Supplies metrics · HTTP"| alerting_7

COMPONENT STACK (8)

  • Mobile ClientSTATEFUL
    Retries once with backoff and jitter
  • Payment ProviderSTATEFUL
    Third party; one charge per key
  • API gatewaySTATELESS
    Checks the JWT, sets a 2.5 s deadline
  • Resource serverSTATELESS
    Orders API; sheds load past 40 in flight
  • BulkheadSTATELESS
    Own pool of 20 calls; a full pool rejects
  • Circuit breakerSTATELESS
    Opens after 5 failures, probes at 30 s
  • Time-series database (TSDB)STATEFUL
    Stores shed, timeout and breaker counts
  • AlertingSTATEFUL
    Pages on-call when a breaker opens

REQUEST & DATA FLOW (10)

  1. Mobile Client → API gateway (Calls with a JWT)[HTTPS]
  2. API gateway → Resource server (Forwards)[gRPC]
  3. Resource server → Bulkhead (Takes slot)[HTTP/2]
  4. Resource server → API gateway (Sheds with 503)[gRPC]
  5. Bulkhead → Circuit breaker (Admits within limit)[HTTP/2]
  6. Circuit breaker → Payment Provider (Calls with key)[HTTPS]
  7. Circuit breaker → Bulkhead (Fails fast when open)[HTTP/2]
  8. Time-series database (TSDB) → Resource server (Scrapes counters)[HTTPS]
  9. Time-series database (TSDB) → Circuit breaker (Scrapes state)[HTTPS]
  10. Time-series database (TSDB) → Alerting (Supplies metrics)[HTTP]
Configure NGINX / Postgres / K8s →60-Sec L4–L7 Diagnostic →