Suggest an editImprove this articleRefine the answer for “What key elements are part of EDA (publisher, subscriber, event bus)?”. Your changes go to moderation before they’re published.Approval requiredContentWhat you’re changing🇺🇸EN🇺🇦UAPreviewTitle (EN)Short answer (EN)Event-driven architecture (EDA) has three key elements: the **Publisher** creates and sends an event, the **Event Bus / Message Broker** accepts, stores, and delivers it, and the **Subscriber / Consumer** receives the event and reacts to it. **Key point:** together they create a flexible, asynchronous ecosystem where services communicate not directly, but through a stream of events.Shown above the full answer for quick recall.Answer (EN)ImageEvent-driven architecture (**EDA**) has three key elements that handle the transmission and processing of events: ### 1. **Publisher** A component that **creates and sends an event** when the state changes. It does not know who will receive the event, it just publishes the fact: > "Payment completed", "New order created". *Example:* the orders service publishes `OrderCreated` after creating an order. ### 2. **Event Bus / Message Broker** An intermediate layer that accepts, stores, and delivers events to subscribers. It provides reliability, routing, and scalability. *Example tools:* **Apache Kafka**, **RabbitMQ**, **NATS**, **ActiveMQ**, **AWS SNS/SQS**. Functions: - routing events by topic, - buffering during load spikes, - guaranteed delivery. ### 3. **Subscriber / Consumer** A component that **subscribes to events** and reacts to them. It can: - update its own data, - trigger internal business logic, - generate new events. *Example:* the notification service is subscribed to `OrderCreated` and sends the customer a confirmation email. ### Overall scheme ```javascript Publisher → Event Bus → Subscriber ``` 1. The publisher publishes an event. 2. The event bus delivers it to all subscribers. 3. Each subscriber processes the event independently. **Conclusion:** > The key elements of EDA are the **Publisher**, the **Event Bus**, and the **Subscriber**. > Together they create a flexible, asynchronous ecosystem where services communicate not directly, but through a stream of events.For the reviewerNote to the moderator (optional)Visible only to the moderator. Helps review go faster.