Almost every event in a business is time sensitive. When a customer makes an online purchase, a sensor flags an impending malfunction, a stock price drops, or a security breach is detected – immediate action needs to be taken. This is where an event-driven architecture (EDA) comes in. An EDA can create, detect, and respond to events as they unfold, helping businesses improve everything from customer experiences to operational efficiency and agility.
Therefore, an event-driven architecture is an integration model built to publish, capture, process, and respond to events across distributed systems in real time. When an event occurs in one application, a message is automatically sent to all the other applications that need to know about it, so they can act on it in turn.
Event-based architectures are decoupled – meaning applications don’t need to be aware of each other to share information and complete tasks. Event information, or messages, can flow freely and automatically between apps. As a result, the EDA model is much faster than the traditional request/response model, where one application must request the specific information, it needs from another and wait for a response before moving on to the next task. Also,due to the decoupled nature of an EDA, they are widely considered best practice for microservice communication
In an event-driven architecture, applications act as event producers (apps that produce or capture events) or event consumers (apps that process and act on events). Producers transmit events to consumers via a broker, aka messaging-oriented middleware, in real time. Consumers can then process the event and trigger other actions, workflows, or events of their own.
In a very simple architecture – when there is a single producer and a single consumer that are in direct communication with each other – brokers can be optional. However, in most enterprises there are multiple sources sending out events to multiple consumers, so a broker, or even a network of brokers (also known as an "event mesh") is needed. When a broker or an event mesh is used, this creates a "loose coupling" of applications.
At SAP, a set of standard events is implemented in the business applications, in particular SAP S/4HANA and catalog those events, based on an open standard, CloudEvents. Based on that standard, automation and development tools can consume those events, or third-party systems can be connected.