Sobes.tech
Senior

What microservice patterns do you know?

sobes.tech AI

Answer from AI

Main patterns (patterns) of microservices:

  • API Gateway — a single entry point for all clients, routing requests to the appropriate microservices, providing authentication, data aggregation.

  • Service Discovery — a mechanism that allows microservices to find each other dynamically, without hardcoded addresses.

  • Circuit Breaker — a pattern for handling failures in dependent services, preventing cascading failures.

  • Saga — a pattern for managing distributed transactions through a sequence of local transactions with compensatory actions.

  • CQRS (Command Query Responsibility Segregation) — separation of read and write operations for optimization and scaling.

  • Event Sourcing — storing state as a sequence of events, which facilitates auditing and recovery.

  • Sidecar — isolating auxiliary functions (logging, monitoring) into a separate process alongside the main service.

  • Bulkhead — resource isolation to prevent failure propagation between services.

These patterns help build fault-tolerant, scalable, and easily maintainable microservice architectures.

What microservice patterns do you know? — Java - sobes.tech