Get startedGet started for free

Benefits of event-driven applications

1. Benefits of event-driven applications

There are several benefits of event-driven applications. A centralized event service can simplify the auditing and control for a distributed application. A log of immutable events can be used for auditing purposes. Events can provide a timed, ordered record of every change to the state of an application. A centralized event service can also help you control access to particular services and data. By requiring authentication and authorization at the event service, you can limit access to each of your event-based services. When using an event intermediary, the producer and consumer of an event are decoupled. Services can create an event without having to send direct requests to any services that consume the event. Services can also consume an event without knowing anything about the service that generated the event. This decoupling means that there's no point-to-point spider web of communication. Each event travels through the event intermediary, which routes the event to the correct consumer or consumers. A producer or consumer is only required to know the format of a specific event. An extra benefit of this decoupling is that new event consumers can be added to your application without modifying any existing services. Microservices applications are sometimes designed to use synchronous request/response calls. The health of a service is affected by the health of the services that it calls, directly or indirectly. When a single service fails... ...it can bring down your entire application. With an event-based architecture, events are generated asynchronously, and events are created without waiting for a response. An architecture can be designed to survive the temporary loss of a service. Events sent to the unhealthy service can be replayed or redelivered when the service comes back up. This asynchronous handling of events leads to more resilient applications. When services are asynchronous, push-based messaging allows clients to receive updates without needing to continuously poll remote services. When using a polling model, consumers must continuously poll to determine when there's work to be done. Polling typically leads to increased network I/O and unnecessary delays in processing. A push-based model allows consumers to automatically be notified when there are events to be consumed. Events are efficiently routed to consumers.

2. Let's practice!

Create Your Free Account

or

By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA.