lundi 27 avril 2020

Microservices design part in WebApi

Hi I am trying to create a project skeleton uses CQRS pattern and some external services. Below are the structure of the solution.

  • WebApi
  • Query Handlers
  • Command Handlers
  • Repository
  • ApiGateways ( here is the interfaces and implementation of microservice calls)

We want to keep controller as thin. So we are using query handlers and command handlers to handle respective operations.

enter image description here However, we use a external microservices to get the data we are calling them from Query handlers. All the http clinet construction and calls will be abstracted in them.The response will be converted to a view model and pass it back to Query handler.

We name it as a ApiGateways. But it is not composing from multiple services. How do we call this part in our solution? Proxy or something? Any good example for thin controllers and microservice architecture

Aucun commentaire:

Enregistrer un commentaire