4

I have an ECS cluster with 3 services(FARGATE), the 3 services are in private subnets. 1 is the web app that is publicly accessible through an Internet-facing Load Balancer and the 2 others are only accessed from the web app. For internal communication, I'm using Service Discovery names. enter image description here

Everything is working but now I'm debating if I need an internal Load Balancer just between the web app and the 2 internal services in case they scale out/in. So, if one of my internal services scales out and I'm using the Service Discovery name for internal communication, it is enough? Or, do I need an internal Load Balancer that can route the traffics to the different service instances?

Does this make sense?
enter image description here

Kstro21
  • 315

2 Answers2

7

Service Discovery is enough. New nodes will be added to the SD name resolution when they are started. Unfortunately many people don't know / use Service Discovery and resort to the more expensive ALB. Good on you for using SD :)

MLu
  • 26,247
2

Cloud map by itself does not support features like sticky sessions that you get from application load balancers. Cloud map also can't do round robin routing like load balancer does to its target groups.

So, for simpler use cases in which you don't care about let's say sticky sessions, using cloud map without ALBs might suffice.