Large Language Model Service Outages: Root Causes and Resilience Engineering
This article examines a representative partial outage of a large language model service and uses it as an engineering case study. It explains how to distinguish capacity overload from dependency failures, then walks through a layered resilience approach: entry-point governance and quotas, queue-based peak shaving and asynchronous processing, graceful degradation, circuit breaking, and multi-zone redundancy. It also covers observability, structured error codes, incident review practices, and a practical deployment checklist for keeping LLM services available in a degraded mode during traffic spikes and dependency disruptions.
1. What a “Partial Outage” Actually Tells Us
A conversational AI and coding service experienced about 1 hour and 49 minutes of partial unavailability on November 3. On the user side, chat requests returned “server busy, please try again later.” The official status page listed the exact start and end times in its incident history, and everything showed as normal after recovery. Once the brand and product specifics are stripped away, this is a highly representative engineering sample: the core path did not collapse entirely, but a subset of requests failed; the system had an observable status disclosure channel; and the incident was bounded to a time window and closed out.
What matters most to developers here is not “how long the outage lasted,” but three signals:
- Partial outage means a capacity or dependency bottleneck, not a global outage.
- Explicit start and end times mean monitoring and an incident timeline were available.
- A single user-facing message means client and backend error semantics were aligned, though error classification was still coarse.
2. Root Cause Categories: Capacity Overload vs. Dependency Failure
The request path for an LLM online service is usually longer than that of a traditional web service: authentication and quota at the ingress, request queuing and scheduling, context assembly, inference compute, post-processing, and streaming delivery. When any stage becomes a bottleneck, it surfaces externally as “busy.”
Capacity overload typically shows: sustained high GPU inference utilization, rising queue latency, throttled concurrency, and errors concentrated during peak hours. Inference is resource-intensive, and batching strategy, context length distribution, and uncertain output length all amplify resource jitter.
Dependency failure shows up when a downstream component (such as a cache, message queue, object storage, logging service, or monitoring/alerting system) misbehaves, causing requests to block or time out in the path, eventually triggering circuit breaking and degradation.
The diagnosis can be reduced to a simple comparison table:
| Observation | Capacity Overload | Dependency Failure |
|---|---|---|
| Error distribution over time | Strongly correlated with traffic peaks | Weakly correlated with traffic; sudden |
| Queue latency | Clearly rising | Possibly normal but with high error rate |
| Resource utilization | Compute saturated | Compute may be idle |
| Recovery method | Eases after scaling/throttling | Self-heals after the dependency is fixed |
3. Resilience Layer 1: Ingress Governance and Quotas
The ingress is the first gate. You need to encode “who can use it, how much, and what happens on bursts” into policy, rather than relying on the backend to absorb everything.
- Tiered quotas: set per-minute request and concurrency limits by user tier to prevent a single caller from crowding out the shared pool.
- Token bucket throttling: allow short bursts while converging to the average over time.
- Priority queues: prioritize interactive requests over batch jobs to protect perceived responsiveness.
- Request slimming: cap context length and maximum output length to compress the resource footprint of long-tail requests.
Illustrative middleware logic (pseudocode):
# Token bucket + priority routingif not token_bucket.allow(user_id, rate=20, burst=40):return too_many_requests("Please try again later")priority = "interactive" if request.stream else "batch"queue.submit(priority, request, timeout_ms=8000)
The key point: throttling is not denying service, but turning unavailability into predictable partial degradation.
4. Resilience Layer 2: Queue-Based Peak Shaving and Asynchronous Processing
Inference requests are naturally suited to “queue + batch.” Changing synchronous blocking into “enqueue—schedule—stream back” keeps the system from collapsing under traffic spikes.
- Message queue peak shaving: the ingress only validates and enqueues; the backend consumes according to capacity.
- Dynamic batching: merge multiple short requests into a single inference pass to improve resource utilization.
- Timeout and retry budget: set a total budget per request; retries must include backoff and a cap to avoid a retry storm.
- Idempotency keys: the client carries a request identifier to prevent duplicate submissions from doubling the load.
Client -> Ingress (auth/quota) -> Queue -> Scheduler -> Inference pool|-> Streaming channel -> Client|-> Degraded template/cached result
5. Resilience Layer 3: Degradation, Circuit Breaking, and Multi-Zone
When a dependency misbehaves, the system should be “available with loss” rather than “fully unavailable.”
- Degradation strategy: return cached answers, simplified templates, or shorter output length.
- Circuit breaker threshold: fail fast once error rate or latency exceeds a threshold, avoiding thread and connection pile-up.
- Multi-zone deployment: make the ingress and scheduling layers redundant across zones, with automatic traffic migration when one zone misbehaves.
- Canary and rollback: roll out new versions to a small percentage, with automatic rollback triggered by abnormal metrics.
One point to emphasize: degraded content must be prepared in advance and drilled regularly. Degradation assembled on the fly is often slower than simply returning an error.
6. Observability and Status Transparency
The fact that the status page recorded start and end times is essentially a form of external observability. Internally, you need a finer metric system:
- Request volume, success rate, P95/P99 latency, queue length;
- Resource-side utilization, GPU memory usage, batch size distribution;
- Dependency-side error rate, timeout rate, connection pool saturation;
- Change events aligned with the alert timeline for fast localization.
It is recommended to make the “user message” a structured error code rather than a single string:
{ "code": "CAPACITY_OVERLOAD", "retryable": true, "retry_after_ms": 1500 }
This way the client can perform backoff retries, and users get a more accurate expectation.
7. Review Mechanism: From Incident to Action Items
A mature incident loop has five steps: detection (monitoring/alerting), localization (tracing and metric drill-down), mitigation (throttling/degradation/traffic switching), recovery (dependency fix or scaling), and improvement (review and drills). The review output must be verifiable engineering items, such as “lower the peak throttling threshold,” “add cross-zone capacity,” or “complete dependency timeout configuration,” each with an owner and a deadline.
8. Deployment Checklist
- Do you have tiered quotas and a burst bucket?
- Do you have queue-based peak shaving and dynamic batching?
- Are degradation templates defined and drilled?
- Are circuit breaking, timeouts, retry budgets, and idempotency configured?
- Do you have multi-zone redundancy and automatic traffic switching?
- Do you have canary release and one-click rollback?
- Are metrics, logs, and tracing integrated?
- Do you have an external status page and structured error codes?
- Do you have quarterly failure drills and archived reviews?
9. Conclusion
A “partial outage” is not frightening; what is frightening is being unobservable, unable to degrade, and unable to roll back. Combining capacity governance, asynchronous peak shaving, degradation and circuit breaking, multi-zone redundancy, and a review mechanism is what keeps a service “available with loss” during traffic peaks and dependency jitter. For more complete managed capabilities, you can look at how Baidu AI Cloud approaches general categories such as container platforms, message queues, object storage, logging services, and monitoring/alerting to carry the resilience architecture described above.
