Roadmap › 1. .NET › Step 27
MS

Microservices & System Design with .NET

Monolith vs modular monolith vs microservices, service boundaries (DDD), REST/gRPC and messaging, API gateways, data per service, sagas and the outbox pattern, resilience, observability, caching, scaling and the system-design interview round.
Quick revision for interview day. Print it or save it as a PDF.

Decide the style

Modular monolith by default → extract a service only for independent scaling, release cadence, ownership or technology. Split by business capability (bounded context), never by technical layer.

Communication

NeedUse
Public/browser APIREST + OpenAPI via gateway
Fast internal callgRPC
"Do this later"Queue (command)
"This happened"Topic/pub-sub (event)
High-volume stream / replayKafka / Event Hubs

Consistency toolbox

Local transaction per aggregate · saga (choreography/orchestration) with compensations · transactional outbox · idempotent consumer / inbox · idempotency keys · eventual consistency shown in UI.

Resilience toolbox

Timeout · retry + backoff + jitter (idempotent only) · circuit breaker · bulkhead · fallback · health checks (live/ready) · DLQ. .NET: AddStandardResilienceHandler().

Observability

Logs + metrics + traces via OpenTelemetry; correlation/trace id everywhere; golden signals: latency, traffic, errors, saturation; .NET Aspire dashboard locally, App Insights/Grafana in production.

System design template

Requirements → estimates → API → data model → diagram → deep dive → bottlenecks & failures → trade-offs. Always mention cache, queue, replicas, idempotency and monitoring.