🏗️ Section 17 · 26 questions
Microservices
26 interview questions and answers in the Microservices section.
Questions in this section
- What is Saga Pattern and When to Use It
- What is the Difference Between Choreography and Orchestration in Saga
- How to Implement Distributed Transactions in Microservices
- What are Compensating Transactions
- What is Circuit Breaker Pattern
- How Does Circuit Breaker Work and What States Does It Have
- What is Service Discovery and Why is It Needed
- What is the Difference Between Client-Side and Server-Side Discovery
- What is API Gateway and What Problems Does It Solve
- What is sharding
- What is the difference between sharding and partitioning
- How to implement horizontal scaling of microservices
- What is Database per Service pattern
- What problems arise when using shared database
- How to organize communication between microservices
- What is the difference between synchronous and asynchronous communication
- How to ensure fault tolerance of microservices
- What is Bulkhead pattern
- What is Retry pattern and how to use it correctly
- What is exponential backoff
- How to monitor a distributed microservices system
- What is distributed tracing
- How to implement authentication and authorization in microservices
- What is Strangler Fig pattern
- How to test microservices
- What tools are used for microservices orchestration
Study navigator
26 essential questions and deep-dive architectural analyses for Junior 🟢, Middle 🟡, and Senior 🔴 Distributed Systems and Cloud-Native Backend Engineers.
📋 Table of Contents
🗺️ Topic Dependency Map
┌──────────────────────────────────────────┐
│ DATA & BOUNDARIES (13-14, 10-11) │
│ 13. Database per Service Pattern │
│ 14. Shared Database Anti-Pattern │
│ 10. Sharding Architectures │
│ 11. Sharding vs Relational Partitioning│
└──────────────────┬───────────────────────┘
│
┌──────────────────────────┼──────────────────────────┐
▼ ▼ ▼
┌───────────────┐ ┌───────────────┐ ┌────────────────────┐
│ DISTRIBUTED │ │ ROUTING & │ │ FAULT TOLERANCE │
│ CONSISTENCY │ │ COMMUNICATION │ │ & RESILIENCE │
│ (01-04) │ │ (07-09, 15-16)│ │ (05-06, 17-20) │
│ 01. Saga │ │ 07-08. Discover│ │ 05-06. CircuitBreak│
│ 02. Choreo/Orc│ │ 09. API Gateway│ │ 17. Fault Toleranc │
│ 03. Dist. Tx │ │ 15. Comm Org │ │ 18. Bulkhead │
│ 04. Comp. Tx │ │ 16. Sync/Async│ │ 19-20. Retry/Backof│
└───────┬───────┘ └───────┬───────┘ └────────┬───────────┘
│ │ │
└────────────────────────┼────────────────────────┘
▼
┌──────────────────────────────────────────┐
│ OBSERVABILITY, SECURITY & OPS (21-26) │
│ 12. Horizontal Scaling & Autoscaling │
│ 21. Monitoring Stack (Prometheus/Graf) │
│ 22. Distributed Tracing (OpenTelemetry)│
│ 23. Auth & AuthZ (OAuth2/JWT Gateway) │
│ 24. Strangler Fig Migration Pattern │
│ 25. Testing (Pact CDC, Testcontainers) │
│ 26. Orchestration Engines & Workflows │
└──────────────────────────────────────────┘
🎯 Recommended Study Tracks
🟢 Junior Track (Core Concepts & Fundamentals)
- Step 1: Communication & Discovery — 15. How to Organize Communication Between Microservices, 16. What is the Difference Between Synchronous and Asynchronous Communication, 07. What is Service Discovery and Why is It Needed
- Step 2: Gateways & Data Isolation — 09. What is API Gateway and What Problems Does It Solve, 13. What is Database per Service Pattern
- Step 3: Basic Resilience — 19. What is Retry Pattern and How to Use It Correctly, 20. What is Exponential Backoff
🟡 Middle Track (Resilience Patterns & Distributed Data)
- Step 1: Circuit Breaker & Bulkhead — 05. What is Circuit Breaker Pattern, 06. How Does Circuit Breaker Work and What States Does It Have, 18. What is Bulkhead Pattern
- Step 2: Sagas & Compensating Transactions — 01. What is Saga Pattern and When to Use It, 02. What is the Difference Between Choreography and Orchestration in Saga, 04. What are Compensating Transactions
- Step 3: Observability & Security — 21. How to Monitor a Distributed Microservices System, 22. What is Distributed Tracing, 23. How to Implement Authentication and Authorization in Microservices
🔴 Senior Track (Distributed Systems Architecture & Scaling)
- Step 1: Distributed Transactions & Dual-Writes — 03. How to Implement Distributed Transactions in Microservices, 14. What Problems Arise When Using Shared Database
- Step 2: Sharding & Horizontal Scaling — 10. What is Sharding, 11. What is the Difference Between Sharding and Partitioning, 12. How to Implement Horizontal Scaling of Microservices
- Step 3: Migration & Production Orchestration — 17. How to Ensure Fault Tolerance of Microservices, 24. What is Strangler Fig Pattern, 25. How to Test Microservices, 26. What Tools are Used for Microservices Orchestration