Implementing the mediator pattern in the vendor service

In microservices architecture, an application is split into multiple services, where each service connects to the other services through an endpoint. There are possibilities that one service may invoke or interact with multiple services when the event is invoked. Segregating the interaction between services is always a recommended approach and solves tight dependencies on other services. For example, an application invokes this service to register a vendor and then invoke the identity service to create its user account and send an email by calling the messaging service. We can implement the mediator pattern to solve this scenario.

The mediator pattern is based on the event-driven topology ...

Get C# 7 and .NET: Designing Modern Cross-platform Applications now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.