Skip to main content
Back to Community & Earn Hub

Surviving the Microsoft 365 24-Hour Outage: Building Multi-Region LLM Fallbacks and Local Circuit Breakers for Enterprise Agents

@rohan_mehta5 days ago·2 min read 1964 views
Surviving the Microsoft 365 24-Hour Outage: Building Multi-Region LLM Fallbacks and Local Circuit Breakers for Enterprise Agents

The Single-Provider Fragility Exposed by the Microsoft 365 Outage

Today (November 25, 2026), a widespread Microsoft 365 24-hour failure—and the resulting internal "Code Red" outage response—took down Exchange, Teams webhooks, and single-region Azure OpenAI Copilot integrations for thousands of engineering teams.

For AI agent platforms, the outage exposed a glaring architectural flaw:

  • Hardcoded Single Endpoint: Most agent loops point directly at https://my-org.openai.azure.com/. When DNS, Entra ID token validation, or regional gateways return 503 Service Unavailable, every tool loop stalls for 30s per retry before crashing.
  • No Local Offline Queue: Teams relying on M365 Graph MCP servers had zero local fallback cache when Graph API stalled.

Resilient Multi-Provider Circuit Breaker Architecture

Production agents should treat LLM providers like interchangeable compute nodes behind a stateful Circuit Breaker:

text
[Agent Turn Request]
         │
         ▼
[Circuit Breaker Router]
  ├── State == CLOSED  ──► Primary: Azure OpenAI (East US / South India)
  │                         (3 consecutive 5xx/timeouts -> Trip to OPEN for 120s!)
  │
  ├── State == OPEN    ──► Secondary: Anthropic / AWS Bedrock (Different Cloud!)
  │
  └── Cloud Unreachable ─► Tertiary: Local VPC vLLM Cluster (Qwen-2.5-32B-AWQ)

Python Async Circuit Breaker Implementation

Here is a lightweight, zero-dependency async circuit breaker that fails over in <5ms once an outage is detected (without wasting 30 seconds waiting on dead TCP sockets for every subsequent user):

python
import time
from enum import Enum

class CircuitState(Enum):
    CLOSED = "closed"
    OPEN = "open"

class ProviderCircuitBreaker:
    def __init__(self, failure_threshold: int = 3, recovery_timeout: float = 120.0):
        self.failure_threshold = failure_threshold
        self.recovery_timeout = recovery_timeout
        self.failures = 0
        self.state = CircuitState.CLOSED
        self.opened_at = 0.0

    def is_available(self) -> bool:
        if self.state == CircuitState.CLOSED:
            return True
        if time.monotonic() - self.opened_at >= self.recovery_timeout:
            # Half-open probe allowed
            return True
        return False

    def record_success(self):
        self.failures = 0
        self.state = CircuitState.CLOSED

    def record_failure(self):
        self.failures += 1
        if self.failures >= self.failure_threshold:
            self.state = CircuitState.OPEN
            self.opened_at = time.monotonic()


async def call_llm_with_failover(providers: list[tuple[ProviderCircuitBreaker, callable]], messages: list[dict]):
    last_err = None
    for breaker, client_fn in providers:
        if not breaker.is_available():
            continue
        try:
            res = await client_fn(messages, timeout=8.0)
            breaker.record_success()
            return res
        except Exception as exc:
            breaker.record_failure()
            last_err = exc
    raise RuntimeError(f"All LLM providers failed: {last_err}")

Key Takeaway

Never couple your primary, secondary, and auth dependencies to the same cloud vendor. Pairing short 8s request timeouts, 120s open-circuit blacklisting, and a local VPC vLLM fallback ensures your agents keep running seamlessly through 24-hour cloud outages.

2 Comments

Discussion

@siddharth_rao5 days ago

The key line here is failing over across different cloud vendors (Azure -> Bedrock/Anthropic -> Local VPC vLLM). Teams that only failed over from Azure East US to Azure West US still went down today when shared Entra ID auth stalled.

@priya_sharma5 days ago

Setting an aggressive 8s timeout + 120s open circuit saves user UX during outages. Nothing kills trust faster than making every request hang for 30s × 3 retries before failing.

Join the developer discussion

Sign in or create a free account to comment (+10 pts) and tag helpful AIStoreHub repositories.