4

Having a hard time figuring out a microservices architecture.

Right now I have an ECS Cluster with two services (TodoService, CategoriesService) running in containers. Both of the services have their own Load Balancer. I'm trying to build an API Gateway where /todos would route to the Todo-app-load-balancer and /categories would route to the Categories-app-load-balancer.

First, is this a good approach to microservices? And second, question from the title.

2 Answers 2

1

First, is this a good approach to microservices?

Yes, there is nothing wrong with this approach.

Can an API Gateway point to multiple Application Load Balancers?

Yes, you can point each method from the API gateway to an entirely different backend resource.

In case of an Application Load Balancer, there are multiple ways of doing this. Probably the easiest is to have a public Application Load Balancer and to create HTTP integration for it. You have to specify the DNS name for the application load balancer as the endpoint. For more information, see this support page.

enter image description here

Other option would be to use VPC Links, which would integration with private load balancers. While this would be recommended for production, it is a bit more complex to set it up.

Sign up to request clarification or add additional context in comments.

1 Comment

That is what I was also wondering about; it is kind of strange for what purpose one should use service integration wish ELB? is it there only to execute SDK-specific commands?
1

Is it a good or bad approach is moreover an architectural decision, But I can suggest using one ALB(Ingress) with different rules can solve your problem, Also in API GATEWAY only allow to add ELB services directly ALB will not but still there is a workaround by adding direct DNS. Here I'm attaching two screenshots for your reference.

enter image description here

Direct integration is not allowed on ALB, but you can use the DNS name manually.

enter image description here

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.