The document discusses Event Driven Architecture (EDA) and its application in enterprise systems, specifically in a healthcare scenario. It outlines key components of EDA such as event generators, consumers, and channels, and highlights the benefits of using EDA for modularity, asynchronous communication, and real-time event processing. Additionally, it addresses potential challenges in adopting EDA and describes how WSO2 products support these architectures.
Introduction to Event Driven Architecture (EDA) by Shiroshica Kulatilake with an agenda outlining its definition, benefits, enterprise implementation, and WSO2 support.
Overview of EDA using a health care system scenario, highlighting typical events that occur in such systems.
Main components of EDA: events, generators, channels, and consumers, elaborating on their roles and interactions. Details on event properties, the importance of self-contained events, and what EDA removes from traditional architectures.
Comparative benefits of EDA in enterprise, including enhanced flexibility, asynchronous behavior, and improved reliability.
Components of EDA including message brokers, mediation buses, service buses, and their functions in the EDA framework.
Real-world application of EDA in health care scenarios, demonstrating its implementation with WSO2 tools.
FAQs about EDA, its relation to SOA, MOM, and EIP, including the distinctions and functional aspects of these concepts.
Typical happenings
• Anew patient registration
• Patient data update
• Patient payment
• Start a laboratory test
• Availability of laboratory results for a patient
• Revocation of insurance policy
• Drug outage
• etc …
Main Components
• Event- entity depicting something which happened
• Event generator - entity which creates and pushes the
event
• Event channel - medium where the event lies before
consumption
• Event consumer - entity which consumes the event from
the channel
11.
Event
• An eventis a piece of information that may be applicable to
one or more objects at a given time
• An event would be
- self contained
- unique
- time relevant
• An event will propose
- a problem
- an opportunity
- a threshold
- a deviation, to its consumer
• Resulting action due to the occurrence of an event could be
- invocation of a service
- triggering a business process
- publishing of another event
12.
Event Generators, Consumers&
Channel
• Event Generators
- publish events in the form of messages
- have no idea who would consume the message
- have no idea about the consequence of the messages
generated
• Event Consumers
- subscribe to published events
- handles events in an asynchronous manner
- oblivious to other consumers
• Event Channel
- acts as the mediator
- handles subscriptions
- handles storage and delivery
13.
What is EventDriven Architecture
• It’s a way of building solutions based on the generation,
reception, processing and sending of events
• Events flow between decoupled services and
components
- Generators and Consumers are oblivious to each other
• Used for building extensible complex distributed systems
which are governed by asynchronous events
- There is no command and control structure
- No request and response mechanisms
14.
What EDP bringsto an Architecture
• Event hierarchies and fine grainedness
• Self describing nature of the event payload
• No special packing for each receiver
• Multiple receivers for a single event
• Responsibility of handling state is with the consumer
• Anonymity when sending an event
• Real time sending of events
• Async nature of delivery
• Guaranteed delivery
15.
What EDP removesfrom an
Architecture
• Co-ordination
• Pre-planned continuity
• Global context with the latest status
• These only work where
- the individual executions are fast
- Actions only happen in a pre-defined order which
does not change frequently
- There is a fixed number of parties involved which the
primary orchestrator knows of
Non-EDA Enterprise Integration
•Collection of Loosely coupled modules
• Enterprise Service Bus to manage the various point to
point integrations
• Business Process Server to do process flows
• Application servers to host the various services
• Central process handling
- via ESB
- via the BPS
19.
Zooming on thecentralized core
Predictive
Behaviour
Linear
Process
Flow
Centralized
Control
Request
Response
Based
Loosely
Coupled
20.
What would EDAbring in
• Looser coupled flows
• Messages are self contained and follow a hierarchy
which helps to subscribe at the correct level
• No time is lost between occurrence and sending of the
event
• Asynchronous nature of event delivery
• Guaranteed delivery makes things more reliable
• Multiple event and multiple event stream processing
21.
Why should anenterprise use EDA
• Enhances the ability to easily plug in more modules as
either event generators or consumers
• Asynchronous nature brings in the ability to design
solutions at run time by getting rid of linear flows
• Brings in the ability for reactive behaviour which suits
situations which need quick reactions
• Can add in more dimensions like monitoring, event
processing for overall system health as well as for
functionality purposes
• Capability to replay events if needed to either simulate,
when state needs to be recreated etc.
22.
EDA based EnterpriseSystem
Service Bus
Message Broker
Mediation Bus
End Service
Business
Process
Service Bus
Application
It’s not asilver bullet ...
• There will be less build-time validation
• EDA creates rapidly evolving solutions
- too rapid ?
- how to keep track of ?
- how to debug ?
• Need of additional tools to figure out how things work
- Visualization tools needed for debugging
- Simulation tools needed for testing
Components in anEDA setting
• Message Broker
- supports the various event based messaging patterns
- Queues/ Topics etc for pub/sub and P2P
- supports reliable message delivery
• Mediation / Service Bus
- brings together the different parties
- generates new events when needed
- can interact with non event based systems
- for business agility event messages would go through ESBs
- when it enters the ESB then would go through EIPs
• Business Process server
- deal with business flows that are triggered when an event occurs
- graphical editor to create the process
Components in anEDA setting
• Data Services Server
- create a service abstraction which can be used for events which
need to interact with data
• Registry
- provides the configuration repository
• Identity and Access Manager
- Authentication, authorization and handling fine grained access
control
31.
Components in anEDA setting
• Activity Monitor
- for monitoring of all activity that goes around
- end to end business message flow monitoring
- identifying, collecting and tracing business transactions
- deriving KPIs from these stats
- taking decisions on these
• Complex Event Processor
- for multiple event and multiple event stream processing
- to go through event sequences and then detecting special events
(threats, opportunities, action points)
- for creating events as results
- for creating alerts
- for pattern detection which could be used for other purposes
FAQ
• Is EDApushing away SOA ?
- No, it still supports loose couple of services but
promotes more run time application definition, with
asynchronous components which act in a reactive
manner - It complements SOA
• Is EDA different to MOM ?
- EDA uses Message Oriented Middleware
infrastructure as the foundation
• Where does EIP stand with EDA ?
- The Enterprise Integration Patterns is about patterns
to integrate enterprise systems. Messaging is one and
the concepts in messaging are used in EDA