1---2name: cloud-design-patterns-53description: Select, explain, and apply cloud design patterns for distributed systems across reliability, performance, messaging, architecture, deployment, security, and event-driven categories. Use when designing, reviewing, or implementing cloud workloads and distributed system architectures.4---56# Cloud design patterns78Map workload constraints and nonfunctional requirements to industry-standard, technology-agnostic cloud design patterns, trade-offs, and Azure service options so a distributed architecture becomes reliable, secure, cost-optimized, high-performing, observable, and scalable.910## When to invoke1112- "Which cloud design patterns fit this architecture?"13- "Review this distributed system for resilience and performance patterns."14- "Design a cloud workload using Azure Architecture Center patterns."15- "Map these requirements to reliability, messaging, security, and deployment patterns."1617## Pattern categories at a glance1819| Category | Patterns | Focus |20| --- | --- | --- |21| Reliability & Resilience | 9 patterns | Fault tolerance, self-healing, graceful degradation. |22| Performance | 10 patterns | Caching, scaling, load management, data optimization. |23| Messaging & Integration | 7 patterns | Decoupling, event-driven communication, workflow coordination. |24| Architecture & Design | 7 patterns | System boundaries, API gateways, migration strategies. |25| Deployment & Operational | 5 patterns | Infrastructure management, geo-distribution, configuration. |26| Security | 3 patterns | Identity, access control, content validation. |27| Event-Driven Architecture | 1 pattern | Event sourcing and audit trails. |2829## Distributed-system fallacies to counter3031Design patterns compensate for incorrect assumptions. Explicitly identify which fallacies the design is exposed to:3233| Fallacy | Design response |34| --- | --- |35| The network is reliable. | Use Retry, Circuit Breaker, Health Endpoint Monitoring, and idempotent operations. |36| Latency is zero. | Use Cache-Aside, CQRS, asynchronous messaging, and locality-aware deployment. |37| Bandwidth is infinite. | Use Claim Check, compression, pagination, and coarse-grained APIs. |38| The network is secure. | Use federated identity, mTLS/private endpoints, least privilege, and the Valet Key pattern. |39| Topology doesn't change. | Use service discovery, Gateway Routing, and resilient client configuration. |40| There's one administrator. | Use External Configuration Store, policy-as-code, and operational ownership tags. |41| Component versioning is simple. | Use Anti-Corruption Layer, Backends for Frontends, and contract tests. |42| Observability implementation can be delayed. | Add Health Endpoint Monitoring, metrics, tracing, logs, and SLO dashboards from the start. |4344## Pattern selection rules4546| Requirement pressure | Prefer | Watch for |47| --- | --- | --- |48| Downstream dependency fails or throttles | Circuit Breaker, Retry, Bulkhead | Retry storms; use backoff, jitter, and idempotency. |49| Write and read models diverge | CQRS, Materialized View, Index Table | Eventual consistency and extra synchronization logic. |50| Bursty producers overload consumers | Queue-Based Load Leveling, Priority Queue, Competing Consumers | Poison messages and ordering constraints. |51| Long-running business transaction | Saga, Compensating Transaction, Scheduler Agent Supervisor | Compensation completeness and auditability. |52| Multiple clients need different API shapes | Backends for Frontends, Gateway Aggregation, Gateway Routing | Duplicated business logic in gateways. |53| Legacy replacement | Strangler Fig, Anti-Corruption Layer | Incomplete route ownership and data synchronization drift. |54| Multi-region availability | Deployment Stamps, Geode, Health Endpoint Monitoring | Data residency, replication lag, and operational complexity. |55| Secretless delegated access | Valet Key, Federated Identity | Over-scoped tokens and missing expiration. |5657## Progressive disclosure and bundled resources5859Load bundled references only when the task needs that category. Relative paths below are inside this skill package.6061| Reference | When to load |62| --- | --- |63| `references/reliability-resilience.md` | Ambassador, Bulkhead, Circuit Breaker, Compensating Transaction, Retry, Health Endpoint Monitoring, Leader Election, Saga, Sequential Convoy. |64| `references/performance.md` | Async Request-Reply, Cache-Aside, CQRS, Index Table, Materialized View, Priority Queue, Queue-Based Load Leveling, Rate Limiting, Sharding, Throttling. |65| `references/messaging-integration.md` | Choreography, Claim Check, Competing Consumers, Messaging Bridge, Pipes and Filters, Publisher-Subscriber, Scheduler Agent Supervisor. |66| `references/architecture-design.md` | Anti-Corruption Layer, Backends for Frontends, Gateway Aggregation/Offloading/Routing, Gateway Aggregation, Gateway Offloading, Gateway Routing, Sidecar, Strangler Fig. |67| `references/deployment-operational.md` | Compute Resource Consolidation, Deployment Stamps, External Configuration Store, Geode, Static Content Hosting. |68| `references/security.md` | Federated Identity, Quarantine, Valet Key. |69| `references/event-driven.md` | Event Sourcing. |70| `references/best-practices.md` | Selecting appropriate patterns, Well-Architected Framework alignment, documentation, monitoring. |71| `references/azure-service-mappings.md` | Common Azure services for each pattern category. |7273## Gotchas7475- **Patterns have trade-offs**: explain why the pattern fits and what new operational burden it adds.76- **Do not implement patterns by name only**: identify the failure mode, data consistency model, and observability requirement.77- **Technology-agnostic first**: select the pattern before choosing Azure, another cloud platform, on-premises, or hybrid services.78- **Cost is part of architecture**: queues, caches, multi-region replicas, and gateway layers add spend and operations.7980## Open Horizons integration8182- Evaluate patterns against the Developer IDP or Agent IDP objective and current Horizon stage.83- Preserve Open Horizons Azure, Backstage, AKS, managed-identity, and evidence boundaries where applicable.84- Route cross-domain sequencing through `open-horizons-orchestration` (`skill`).8586## Output template8788```markdown89## Cloud design pattern recommendation9091**Workload:** <system or feature>92**Primary drivers:** <reliability | performance | messaging | security | deployment | migration>9394| Requirement or risk | Recommended pattern | Category | Why it fits | Trade-off | Azure option |95| --- | --- | --- | --- | --- | --- |96| <risk> | <pattern> | <category> | <reason> | <cost/complexity/consistency impact> | <service or none> |9798### Architecture notes99- <how the selected patterns work together>100101### Validation102- <checks, tests, metrics, or runbooks needed>103```104105## Quality gate106107- [ ] Requirements and nonfunctional drivers are mapped to explicit patterns.108- [ ] At least one trade-off is documented for every recommended pattern.109- [ ] Distributed-computing fallacies relevant to the workload are addressed.110- [ ] Bundled references are loaded only for categories needed by the task.111- [ ] Azure service mappings are presented as options, not mandatory choices.112- [ ] The recommendation covers reliability, security, cost, operations, and performance impacts when relevant.113114## References115116- [Cloud Design Patterns - Azure Architecture Center](https://learn.microsoft.com/azure/architecture/patterns/)117- [Azure Well-Architected Framework](https://learn.microsoft.com/azure/architecture/framework/)