0
votes

I've just started working with docker and I'm currently trying to work out how to setup a project using microservice architecture.

My goal is to move out different services from the api and instead have each one in their own container.

Current architecture

enter image description here

Desired architecture

To

Questions

  1. How does the API gateway communicate with the internal services? Should all microservices have their own API which only accept communication from the API gateway? Any other means of communications?
  2. What would be the ideal authentication between the gateway and the microservices? JWT token? Basic Auth?
  3. Do you see any problems with this architecture if hosted in Azure?
  4. Is integration testing even possible in the desired architecture? For example, I use EF SQlite inmemory for integration testing and its easily accessible within the api, but I don't see this working if the database is located in it's own container.
  5. Anything important here that i've missed?
1

1 Answers

0
votes

I had created an application that is completely a micro service based architecture running on AWS ECS(Container Service), Each microservice is pushed on container as Docker image. There are 2 instances of EC2 are running for achieving High Availability and same mircoservices are running on both instances so if one instance goes down another can take care of requests.

each microservice use its own database and inter microservice communication is happening using client registry on HTTP protocol and discovery, Spring Cloud Consul and Netflix Eureka can be used for service discovery and registery.

enter image description here.

Please find the diagram below :