good day i read some books about microservices architecture, but i still have question.. One of them is about situation when you need to retrieve data about some entities, which connected with other... for example: we have order and user microservices, for example each order have some information about user and customer wants to retrieve user orders so i see three ways to achieve this:
- Client app makes request to orders microserve and after makes n request to users microservice to retrieve user info the order
- Client app makes request to orders mircoservice which make inter-request to users microservices
- Orders microservice db store necessary information about user
For first case - it is complex for client app to construct and aggregate data together from two sources (orders and users)
For second case - if we have more than two microservices then total request time will grow
For third case connected with data consistent problem (user changed data, but order service db does not update yet)
which case is most used?
and small question #2 - in case of microservice and web api application - each microservice contains only one or maybe two controllers?