![Building Serverless Microservices in Python](https://wfqqreader-1252317822.image.myqcloud.com/cover/764/36698764/b_36698764.jpg)
上QQ阅读APP看书,第一时间看更新
Many-to-many communication microservice patterns
For many-to-many communication, we use publish/subscribe, which is a messaging pattern. This is where senders of messages, called publishers, do not program the messages to be sent directly to specific receivers; rather, the receiver needs to subscribe to the messages. It's a highly scalable pattern as the two are decoupled:
![](https://epubservercos.yuewen.com/B0DCF8/19470380508818406/epubprivate/OEBPS/Images/58541d05-3ffb-4cb5-a28f-8c9cd952e78e.png?sign=1734420914-FFoEiu5C2HLptCjF9brePLKpXDmQYfaE-0-23ff54cdf62f6b986b768fa8b56825f8)
Asynchronous messaging allows a service to consume and act upon the events, and is a very scalable pattern as you have decoupled two services: the publisher and the subscriber.