0
0
Microservicessystem_design~12 mins

Graceful degradation in Microservices - Architecture Diagram

Choose your learning style9 modes available
System Overview - Graceful degradation

This system is designed to keep working even when some parts fail. It uses microservices to handle different tasks. If one service fails, the system still responds with limited features instead of stopping completely.

Architecture Diagram
User
  |
  v
Load Balancer
  |
  v
API Gateway
  |
  +-------------------+-------------------+
  |                   |                   |
Service A          Service B           Service C
  |                   |                   |
Cache A            Cache B             Cache C
  |                   |                   |
Database A         Database B          Database C
Components
User
user
Sends requests to the system
Load Balancer
load_balancer
Distributes incoming requests evenly to API Gateway instances
API Gateway
api_gateway
Routes requests to appropriate microservices and handles authentication
Service A
service
Handles core feature A of the application
Service B
service
Handles core feature B of the application
Service C
service
Handles optional feature C that can degrade gracefully
Cache A
cache
Stores frequently accessed data for Service A to reduce database load
Cache B
cache
Stores frequently accessed data for Service B
Cache C
cache
Stores frequently accessed data for Service C
Database A
database
Persistent storage for Service A
Database B
database
Persistent storage for Service B
Database C
database
Persistent storage for Service C
Request Flow - 10 Hops
UserLoad Balancer
Load BalancerAPI Gateway
API GatewayService C
Service CCache C
Cache CService C
Service CDatabase C
Database CService C
Service CAPI Gateway
API GatewayLoad Balancer
Load BalancerUser
Failure Scenario
Component Fails:Service C
Impact:Optional feature handled by Service C becomes unavailable, but core features continue working
Mitigation:API Gateway detects failure and returns a simplified response without Service C data, allowing system to degrade gracefully
Architecture Quiz - 3 Questions
Test your understanding
Which component directs user requests to the correct microservice?
AAPI Gateway
BCache
CLoad Balancer
DDatabase
Design Principle
This architecture shows graceful degradation by isolating optional features in separate microservices. If one service fails, the API Gateway can detect it and respond with limited functionality, keeping the system responsive and user-friendly.