Event broker 是将事件传递给事件处理器还是事件处理器始终监听事件 Broker

Is Event broker pass events to event processors or event processors always listen to the event Broker

我是事件驱动架构的新手,正在尝试理解这一点。我在 google 中搜索。我研究了一段时间。 在某些网站上,他们说

Event processors always listen to the Event Broker and receive the event.

并且在某些站点中

Whenever the event broker receive any event from event creators, it passes the event to the all subscribers.

我很困惑。哪个是正确的?请帮我解释一下。请帮我一些 google 参考资料。

如有任何帮助,我们将不胜感激。请用你所知道的任何知识来回答。

我相信这两种说法是正确的。他们只是用不同的术语和不同的角度说同样的话。

消费者可以从代理中提取事件,或者代理可以推送事件给消费者。

第一个语句是从"consumer""event processor"的角度写的:

Event processors always listen to the Event Broker and receive the event.

听起来消费者很闲,正在等待经纪人的通知。所以在这种情况下,似乎是经纪人将事件推送给消费者。

第二个陈述说同样的话,只是从经纪人的角度来看:

Whenever the event broker receives any event from event creators, it passes the event to the all subscribers.

换句话说,在新事件发生的那一刻,事件代理知道它,它会将它广播给所有感兴趣的人 "subscribers"(或消费者,或事件处理器)。

所以这个和之前一样,消费者,订阅者或者事件处理器都是同一个概念。他们都闲着,等着有事情发生时被经纪人通知。

所以,就我而言,这两个陈述的意思相同。