Monolith advantages (staff engineers still defend these)
- Simple deployment — one artifact, one rollback
- Refactoring — IDE finds all callers; no cross-repo versioning
- Transactions — local ACID, no sagas
- Debugging — single process trace, no distributed tracing required
- Latency — in-process calls, no network
Fowler's MonolithFirst: prove domain model in monolith; extract when pain justifies ops tax.
Microservices advantages
- Independent deploy — ship payments without retesting catalog
- Independent scale — scale hot services only
- Technology diversity — Go for ingest, Java for ledger (use sparingly)
- Fault isolation — blast radius containment (if truly decoupled)
- Team autonomy — Conway's Law: architecture mirrors communication structure
Costs you must articulate in interviews
| Cost | Manifestation |
|---|---|
| Operational | N deploy pipelines, N on-call rotations |
| Observability | Distributed tracing mandatory (Observability track) |
| Consistency | Sagas, idempotency, outbox (Distributed Systems) |
| Latency | Network + serialization on every hop |
| Testing | Contract tests, staging env complexity |
| Data | No cross-service JOINs; denormalized read models |
Conway's Law
Organizations design systems that mirror their communication structures.
If teams are organized by layer (all DBAs, all frontend), you'll get layer services. Stream-aligned teams (vertical slice) produce capability services.
Shared libraries vs shared runtime
- OK: thin client SDK, auth middleware, observability bootstrap
- Risky: shared domain model JAR coupling all services to one release train
- Never: shared database schema across services
Modular monolith (middle path)
Single deploy, module boundaries enforced by compiler/package rules (Java modules, Go packages, Nx boundaries). Extract to services when module API is stable.
Popular at senior startups before 50+ engineers.
When interviewer asks "microservices or monolith?"
Answer structure:
- Team size and org structure
- Deploy independence need
- Scale heterogeneity
- Operational maturity (K8s, mesh, observability in place?)
- Default monolith/modular monolith unless clear pain
Further Reading
Hands-On Tasks (Optional)
Architecture drills and whiteboard exercises. Assumes Communication & Data Transfer and Distributed Systems fundamentals.
- Argue against microservices15m
For a 10-engineer startup shipping weekly: list 5 concrete costs of microservices (deploy, debug, data consistency, latency, hiring) and when you'd revisit the decision.