Event-Driven Architecture or EDA is defined as an architectural pattern that uses events to maintain communication within a system. It leverages a message broken to publish and consume events asynchronously. Both producers and consumers are unaware of each other. In simple words, Event Driven Architecture is a method by which we can achieve loose coupling between services within the system.
Events: Definition
An event is a data point to represent state changes in a system. Whenever a consumer makes a change, an event is formed. However, there is no specification as to what and how the state change should happen.
Components of Event-Driven Architecture (EDA)
The Event-Driven Architecture has three components under it. Let’s see them individually.
1. Event Producers:
They produce an event for the router.
2. Event Routers:
The event routers filter and push the events produced by producers to the consumers.
3. Events Consumers:
They consume events to reflect the state changes in the system.
Patterns of Event-Driven Architecture (EDA)
There are numerous ways for implementing EDA in your system depending upon your use case. Let’s see some of them:
Advantages of Event-Driven Architecture (EDA)
Producers and Consumers are unaware of each other.
The system becomes highly scalable and distributed.
Agility is improved.
Guaranteed delivery
Adding new consumers is easy.
Challenges of Event-Driven Architecture (EDA)
Error Handling is difficult.
The system integrated with EDA is complex in general.
Exactly once, in-order processing of events.
Conclusion
Where the way of Event-Driven Architecture depends on the use case, there are various use cases like Metadata and Metrics, Server and Security Logs, Integrating heterogenous systems, Fanout and parallel processing, etc. In addition, we can check out some of the examples of the architecture in NATs, Apache Kafka, Amazon EventBridge, Amazon SNS, Google PubSub, etc.
pragyaasapkota / System-Design-Concepts
Though the concepts of system design might be tricky, let's see them individually to their core concepts and have a better understanding.
System Design
System design defines system elements like modules, architecture, components, and their interfaces and data for a system based on the specified requirements.
This is an index for the concepts of the system.
If you wish to open these in a new tab, Press CTRL+click
S.N. | Table of Content |
---|---|
1. | Caching |
2. | Network Protocols |
3. | Storage: The Underrated Topic |
4. | Latency and Throughput |
5. | System Availability |
6. | Leader Election |
7. | Proxies |
8. | Load Balancing |
9. | Endpoint Protection |
10. | HTTPS: Is it better than HTTP? |
11. | Polling and Streaming |
12. | Long Polling |
13. | Hashing |
14. | CAP Theorem |
15. | PACELC Theorem |
16. | Messaging and Pub-Sub |
17. | Database |
18. | Logging, Monitoring, and Alerting |
19. | Distributed System |
20. | Scaling |
21. | Event Driven Architecture (EDA) |
22. | CQRS |
23. | Message Queue |
24. | Architectural Patterns |
25. | Enterprise Service Bus (ESB) |
26. |
I hope this article was helpful to you.
Please don’t forget to follow me!!!
Any kind of feedback or comment is welcome!!!
Thank you for your time and support!!!!
Keep Reading!! Keep Learning!!!
Top comments (0)