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 ...