Aither shows an approach how to bootstrap a microservice system with Hemera and docker. You can scale your worker in seconds and because we use NATS as “nervous system” for our distributed system we do not have to carry about service-discovery or load-balancing of hemera-services. We use traefik to load-balancing the api-gateway.
This configuration will setup:
- Hapi http server which act as api-gataway to the Hemera services.
- Microservice example which is responsible to add two numbers.
- NATS server the underlying messaging system for Hemera.
- Zipkin dashboard to monitoring your distributed system.
- Natsboard dashboard to monitoring your NATS system in realtime.
- Traefik modern HTTP reverse proxy and load balancer made to deploy microservices with ease.
Running the system
Scaling the system
docker-compose scale worker=5 api=2
Run load test
npm install -g artillery artillery run loadtest.yml
Start a request against load balancer
NATS monitoring endpoint
thanks most of all to the community who create these awesome opensource software and thereby making it possible.