A complex event is an event indicated by the asynchronous occurrence of multiple other, often simpler, events. To use a non-software example: A person throwing a ball, a person swinging a bat, and a person running to a base are each individual events which compose the complex event of a baseball game. In software, Complex Event Processing (CEP) is the ability to recognize the complex events indicated by the asynchronous occurrence of individual business events within a software system—often indicated by the exchange of messages between services—and react accordingly. Reactions may include generating a new event, deleting logical duplicates, and other actions.
Independent consultant Larry Fulton recently gave a webcast on CEP and SOA and discussed how the two can work together. CEP helps align system processes with business processes, explained Fulton, by interpreting incoming business events and simplifying them into new messages for consumption elsewhere in the SOA, thereby reducing the volume of work to be handled upstream. In turn, having a SOA in place allows the advantages gained from implementing CEP in one area of an organization to be more easily implemented across multiple business domains.
Below are three points taken from Fulton's webcast for leveraging CEP with SOA:
- CEP and SOA should be looked at from two perspectives. First, CEP should be seen an implementation choice within an SOA. CEP can be used to implement new business capabilities, such as process simplification and correlation, as services. Second, CEP can be seen as a source of services. If there are systems in place using CEP, they may contain services that can be wrapped in new ways to be used elsewhere within a SOA.
- If you are unsure whether you need CEP, start by understanding your business events to determine whether CEP is a good fit. Fulton recommends speaking with business people to discover which events occur in a process and when, and which ones are most significant to business goals. He also recommends analyzing low-level events that happen at the point of business, as doing so often leads to new insights of the business as a whole.
- CEP will benefit from having a single library of messages, rather than many smaller libraries where duplicate titles or messages may exist. Fulton suggests that, in general, any time an organization looks to share messages beyond basic point-to-point exchanges, such as copying or rerouting messages between multiple systems or services within a SOA, it should look to create a single bucket of definitions for information. Implementing CEP may make that need apparent, but CEP will operate better with such a library in place.
For more, watch the webcast on CEP and SOA (Registration Required)