Skip to content
thesarfo

Reference

Microservices: Monitoring & Software Enablers

The five principles of microservices monitoring, common monitoring tools, service virtualization, and the Spring Cloud components that enable microservices.

views 0

Microservices Monitoring

Monitoring is the control system of the microservice. As microservices grow in number, it becomes harder to understand performance and troubleshoot problems. Given the vivid changes to software delivery, monitoring is required. There are five principles of monitoring microservices:

  1. Monitor containers and what’s inside them.
  2. Alert on service performance.
  3. Monitor services that are elastic and multi-location.
  4. Monitor APIs.
  5. Monitor the organizational structure.

These principles address both technological changes associated with microservices and organizational changes related to them.

Microservice Monitoring Tools

  1. Hystrix dashboard
  2. Eureka admin dashboard
  3. Spring Boot admin dashboard

Microservice Virtualization

Microservice virtualization simulates the behavior of specific components in component-based applications (cloud-based apps, SOA, API-driven architecture). Service virtualization also reduces cost and saves time — combined with it, an organization can develop applications that can be delivered from various locations and dissimilar environments.

Spring Software Enablers of Microservices

  1. Spring Cloud Config Server — provides an HTTP resource-based API for external configuration in the distributed system. Enable it with @EnableConfigServer.

  2. Netflix Eureka Naming Server — a service discovery server, providing a REST interface for outside communication. A microservice, after coming up, registers itself as a discovery client. There’s also a Eureka Client module that interacts with the Eureka server for service discovery and balances client requests.

  3. Hystrix Server — acts as a fault-tolerant, robust system, used to avoid complete failure of an application, via the Circuit Breaker Mechanism. If the application is running without issue, the circuit stays closed. If an error is encountered, the Hystrix server opens the circuit, stopping further requests from calling the service.

  4. Netflix Zuul API Gateway Server — a gateway server that all client requests pass through, acting as a unified interface to a client. Has an inbuilt load balancer to balance incoming client requests.

  5. Netflix Ribbon — a client-side Inter-Process Communication (IPC) library, providing a client-side load-balancing algorithm (Round Robin by default). Provides fault tolerance, load balancing, multiple protocols, caching, and batching, etc.