-
Book Overview & Buying
-
Table Of Contents
Microservices Design Patterns in .NET - Second Edition
By :
The aggregator service is introduced to optimize how the UI interacts with the application's microservices. We must never forget that the system is only as good as its weakest link. Since this new service is the link between the UI and the rest of the services, it needs to be well-built and able to handle various scenarios. As such, it is essential to implement best practices as much as possible and practical and ensure that all service interactions are handled efficiently. One quick win is asynchronous programming, which comes out of the box in .NET. We will review why this helps us next.
Asynchronous programming allows a program to perform non-blocking operations, enabling multiple tasks to run concurrently. This paradigm is beneficial when dealing with waiting operations, such as network requests to APIs. In a synchronous program, tasks are executed sequentially. For a task such as an API call, the program halts...