Event Processing - The Next Generation; March 2009
-
Upload
opher-etzion -
Category
Technology
-
view
1.056 -
download
0
description
Transcript of Event Processing - The Next Generation; March 2009
IBM Haifa Research Lab – Event Processing
© 2008IBM Corporation
������������� �� �������������������
���������������
�������������������������� !��
������������� ����������"��#$�����%&"
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
'������ ��� �� ��� �(
I am wearing three different hats today
The EPTS chair hat – a catalyst in establishing
this community
Once a week I am wearing the Professor hat and teach an event
processing course
The industrial hat: IBM
(which pays my salary and in return occupies most of my time)
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
�)�*����+�������������� ����,-./
� ������������� ���������0���1-2� ����� �)����������3������4������5��������� � ���6
� �����������5 ��������� � �4��� 6
� '�#������ �������� �����������������������#�� �� ���)������������������
� ����������!��#�)������#�����#��#�
� ������������� ��������������� �� �� ���� 4� ��
� "�� ��� 4�����#��������������� ������7�������������
� ������7�#��)���4 ������4������������7������4��������!8�
� '���2����!�����#�&������� 4���)����������!4�����������������#������� ������� ��������
� ������#�����������4��#����������� ����������#����������������0� � ��������� $����� ��������������$��������� ����$�#���� ���� 3�
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
�4�����
What are the current Research Challenges ?
Survey of recent projects
Summary
What is event processing ? What is it used for?
A quick Introduction second generation
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������������� ������������
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
����#���)����������!4�������������
Every business person reacts to events, from time to time
Well… there are all sort of reactions…
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
We answer phone calls everywhere
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
We have to make arrangements when our flight is delayed
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
� ��� ��7������������������4�������� 4�������������
I closedthe deal with the Canadians
We closed two huge deals in a single day,It is a good opportunity to send all the team toLas-Vegas
I closed the deal with the Australians
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
'����������������(
�9������� ������� ��������0��������������������� �)�������� ������3��� ��0�������� ������)������������3�4������0�� ������!� �� ���4�$������������������3��������������)��
� ���� �4������#� ���� ��������������������0� ��4�����������)�5������ ���� �63������������#�������
� ������ �)���������������4������ �+�
� :�#��������#���!���
� ��������;��� ������������<7�8��7
� &�����#���!��
� 9��������#���!��
� 9�)�5!4����������4����6 �����#�!)�������������
� �������������)���07�������4�4����������������#�!)������� �3$�� �2��� ��0����������3$���#� �)������������#����������#���������
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
�������������9������4���
Consume and react to either raw or complex events
Generate and may publish events
perform operations on events
Event Processing
EventConsumer
EventProducer
'������4��#��������8�� ��������&�=4���2&�����������#� �� !4����������#���������+�
������#4���$�����������#���4 ��������#�����#�� ���)�#�>��8�7�����������
?�����$�������� $������$��4��$���������������$�#������������
CEP
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
DetectDecide
Respond
�����4������ ������ �4�������*��4�
RTE
Information Dissemination
BAM
Predictive ProcessingActive Diagnostics
Reactions to events are done as part of business transactions – achieving low latency decisions, and quick reaction to threats and opportunities
Getting the right information in the right granularity to the right person at the right time
Diagnose problems based on symptoms and resolve them
Quick observation into exceptional business behavior and notification to the appropriate people.
Mitigate or eliminate predicted events
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
?��� ������� ��� �� ������)��� ���������������������� &������ ���
� ������������4 !���!4����#4��������������?��� ������� �����#�������������� � �##�����#�!�8����������������
� �������#� ������)����������� ��� � ��������4 !�����������$��2����� ��8������#����8���������������0#����������3
� �����#������4��#����������)���4���������4������#������� ������� �@ ���������
� ��������������� ������������ ����������� ��������������������������������������������������� �������� ������������ �������������������
� ��#���������4�#�!�������#�4�#���� �������7�������������� ��
� ��#���������4�#�!��� �� ���#�4�#���� ������ 4���������� ��
Complex Event ProcessingTransactional Context Transactional Context
TransactionalInput Queues
Filter andTransform
Logic
PersistOrders toDatabase
CEP Routing, Aggregation,
Temporal Logic
OutputFor
execution
AggregationLogic
Database Update
TransactionalOutput Queues
INPUTJMS
Pub/Sub
Aggregated Order Notification to CEP
Direct passthrough of selected messages
Solution:
Configurable aggregation rules
•Thresholds by currency
•Thresholds by time
•Thresholds by
counterparty/client�
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
;�������&��4������8�� ��2 �9����� �������
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
%���������������+�������������#�%������������� ���� �����A����� ���������� ������
DetectDecide
Respond
������������8�#�4���� 4������� ������0����������������� �3�2 ������)�������������4���4����!���#��� 4������� ���4�� �������#��������>�������)�7���������#������������#���7� +�
��� ���+����!�#������4������4���������)�7������,�#�)��������� ��������.-B�������������)�����
��� ���+������������� ��������.-1?$���#�!�#������4������4���� �)�����#�)�������������4���
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
&�������9������ ���+�� ����������
��#���#4���������9�����+� ���������,C���������������
7���4��#�����#4��������������,��4���� ���4���#����!�8�������������
� ���������1-����������������#4������������������!������ ��#�������������.C� ��4���
� 9���#4�������#������!��� �����������������!�����4�������
�4�������"�����9�����+� 9�;���������#4��7������
!������8����� ���)��������������������4�
� 9����������� �����!������8����� ����������$�!4��#�#���������������84��7������,��4��
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
9�D4�8�����#4����������,�#���������
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
.�� ��#�,�# ������������������������ �
.�� �������������+�������$����������#$�����#2������� ����7�����������)������������� 4� ���)�����)�!4����7��������)�����������)���������������������� ������� �������
,�#� �������������+���������#$�#�����!4��#$������� �� !�##�#$�#���!���#�05���63$��*���4��D���&�=4��� ����$� ���������������
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
���+!����������������4������������� #��
������������� ����7�8
�#�� �# ��
������������� �9 ���
��!�������
��4 ��
��#4��
������;������
��!������������
&4���
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������� ����
?�����?�
?�����;
�,
�1
�E
�����+����#��!���(
���������+�;,?������
��������#������+9�������)�����
���������������+�9������4���
�F
?�����?�
��#������4������#��
�,
�G
�1
�F
�C
�.-
�/
�E
�.
�..
�.,
�.,
�# ������
9 �� ���+�����
�H
���������������+�;����44��?����
�H
�/
?�����+����!������. �C
�.1�.G
�.C
�.F
�.H
�.E
�./
�,-�.-
�..
�.,
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
'������������4������������������� ���(�
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
���� 4������������������
:���
?4������
�� �������
������
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������ ��������#�;������ ��
� �������� 7�����������5����4��������� 6 � 7������������������ ���#����#����������� �� �� ��� � ���$����@
� ��������������4������0��#�����3������� �+
�4���2��<9�������
�4���2��<9�������
����� �������
����� �������
���#������
���#������
����<������ �� ������� �
����<������ �� ������� �
� !�##�#� !�##�#
IBM Research
© 2008 IBM Corporation��
Engineering Oriented Challenges
EPNEPNEvent
ProducerEvent
Consumer
EventProducer
EventProducer
Event Consumer
Event Consumer
EPA
Pattern
EPA
Pattern
EPA
Pattern
EPAEPA
��#���#4���9 ����+������� �����!����� ��� �������
��#�����2��� 4�����
&4��� ���#���������
9��� � �����9 ��������������
���������#���
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
?4��������������#�;������ ��+�
?� ��?4�#�����
�� �������4���
����������#������2�� ���������������
%��#��� ����#���#����������
;������!���#������� �
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
:�����������#�;������ ��
�� ��������������������
���4����"�� 4� ����
� ����� ���������
�4��#2�� �����+�
����#����$����4��������$�#�!4 ���
&4�2�� �����+�
������ $��4#����
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������������������#���!�� ������4� ���#�#������
Why a decision is needed?• Event Occurred• Event Pattern has detected• Fact has changed• An explicit request • Related to other decision
Which information is neededIn order to make this decision?• Current state• Past events• Past states• Future states and events.
How the decision should be Done? • Inference from facts and rules• Match patterns on event history• Apply optimization tools
Business UserView Point
Islands of tools
Implementationdriven tools
Dependent Decisions
GapsIn coverage
Ability to manageLarge complex
Decision network
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
����������#�������������� ����
�������� �)�#����#�������4���������+� ����+��
������)����������0 ��3������)��������������0��3$�������)���#�������0��3
� �������+�;4������������0�&��3� ����+��
�I�7���4�4��������0 ��3�8�7������������0�&��3����#���#������������09���)���3
�������� �)����4����������4�������+J �������������������# ����J ����� �� �� ������J ��� ������� ��������� ��������� J ������� ��� ���#�������
Most ImportantConnection
Business User Orientation:The user should be able to author, modify, understand, and audit individualComputerized decisions, as well as theRelationships among them
EP
BRMSAnalytics
Gaps
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
?4������;������ ���
������� ����������
������� �
94� ���#��������
%��#��� :���������������
������������
&�����������������
������� �
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
9��4���)���&���������K���
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������ ���&�����������������
������ ?4���� :��!����)��� �������
%&"�� ���
���#4�����4#����������
������'L�
���������
������ 4���2��
�����4��)�������������
��������9���)���
�� �� �� ��
�������������
�������
:��������)������������
������������
������#��������"
���
&�����������������
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������� ������������������ �������������������� ���������
Producer_1
Producer_2
Producer_P
.
.
.
…
Consumer_1
Consumer_2
Consumer_C
.
.
.
Stratum_1
.
.
.
Agent_1N1
Agent_12
Agent_11
Stratum_2
.
.
.
Agent_2N2
Agent_22
Agent_21
Stratum_S
.
.
.
Agent_SN2
Agent_S2
Agent_S1
�����9)���� �� ��M�?��7�4��7�8���������
N4���&�!�����
IBM Research
© 2008 IBM Corporation��
RFID Store Scenario - 3 Stratum Levels
4,48529,904Third stratum – 2 agents on single node
38
277
21,418
Average derived
events rate (event/s)
693Second stratum – 2 agents on single node
1,399Centralized – all the patterns are detected by multiple agents on same node (8
agents)
21,419First stratum – 4 agents on single node
Average input events
throughput (event/s)
Levels
FilterLoc= “Cashier”
FilterLoc = “Exit”
FilterLoc = “Shelf”
FilterLoc = “Cart”
Sequence
Sequence
Atleast
Atleast
TagRead
Tag ReaderTag
ReaderTag ReaderTag
Reader
TagRead
TagRead
TagRead
ProductAtCashier
ProductExitStore
ProductInCart
ProductOnShelf
ProductLeftAtCashier
ProductReturnedToShelf
AtLeast5ProductsOf
SameKindReturnedToShelf
AtLeast10ProductsOf
SameKindSold
Stratum1 Stratum2 Stratum3
105.37%121%Additional node improvement
11802%13562%112 nodes improvement
4,48521,419*4+693*107+
29,904 = 189,731
(upper limit)
3 Stratum Levels – second stratum has the slowest
performance. Maximal flow performance can be achieved
by combination of 1 node in the third level, 107 nodes in the
second layer, 4 nodes in the first level
381,399Centralized
Derived events total
rate
Input events total
throughput
Implementation
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
��� ��� ��� ��� 2 9��������������� �����2"�� 4� �+
9������������#����������������������+
"�� 4� ��;����4��+������������� ��� �������
"�� 4� ������2;����4��+������������������ ����
����4��
"�� 4� �������2 ���2;����4��+�
���������������� ������#� ���2 ���
����4��
��� ���+��9�91����4�� ���;���#���8��
��9�91�
9 �� ����@
9 �� ���
��9���������+
@�
����������� �����
�������������#������#
�����4��� ���������
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
������� ����������������� �
�����������4� ��������4������������������#�����)���7����������!���#��� ��4���)�#��� ��#����������
����!���������� ����&���������� �� �� ���#����������)���� �2�����!4���������������9�!4��������������� ��4��#��� �������4���)��� ������#��������)��� ������� �7����#������ �8�����������#�7��������#���#��4��)��
������&���2O��$�����%&"�
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
&������ ������9����������
� ������9���)���+��9���)������������������� ����7�8������#�����!����� ������0#���� ���� $���� ������$��4!�4 ����$�����#�����$�� ����������������#@3
� �)�� ������)���+�9�����������4�������������)����������$�����$����#������ �$���� 4������������#�����#����
%&"�0������#����,--/3�������&�!�����
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
�� ���������������� ������
� 9���� 4� ����#����4���� #���������������������4�������������������������)��� �+
� ���������
&���������4��������)��� ��#�� �������
�������4������������������4���
��������� �����
� ��� �����������
9� ���� 0�3����������4��������!�!����)�=4����������
;��4������������!�!�����������#�����#�!)��4����� �����
����#����4������#��� �� ����� ������� ��#�� �������4�����
����+��� �� '�����8�4
0K�����4���������7����9�� ���3
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
���������������
� ���"����������#��#�����4����������������4����"�� 4� ��#����!���7�8��7�
� ����7�8�������������������������������������#��#������!������"���!�� ���#)�� ����#���������������������4 ���
������9����I� ��
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
�� � �������
� ?� ���?4�#��������������������� �� 7����?O��I�����4��
� ������������� ����������� �����#��:���K��� ������������� ��� 4���2��� �������� ������������
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
!�����"����� #����$� ����%%
��������� �������&� #�� ���� �����
� ���������4��+�P4���,--E
� ��������#�!)�����
� ���4#��
� 9������#���������������M
� ���)����������!�����#� �������M
� 9���)������#�� ��4�� ���
��&�'�����
� �� ��� ��#�������!4��������������� �0�������� ������7�������3��4�#������#�� �7���������$����4�$� �� �����)�
� �#�����)�������������#��#������$��#�����)����������������#��#�� ���������0!4�������7�������!� ��������#��#�� ��������3$� �8�� ��4�����������#��#����������������)���
� %��������!������������������ ���������#� ��#��������
������� � �����
�
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
;��4���
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
'����#�7���������#�����#����� ����������"�������� �&�������������!����
� '�)�����4��#�#�(�05�4�������&4����9�����#6$����!����*��%����3
� ����������4�#�����)�!����#����
� ���7�������#���4�#����#���������)�07���@ ��� ��������3$���#�#�������#� ��������#4��
� ������7����� �� #�!8���������=4����)���������#���������)$�����!�������$���#��������������)$���������� 4���)
� ������������#������#� ���#� �������4��� ����
� 0 )��##����3+���D"������������2 ����������#��#����!��#����������!����)�
� 0 )��##����3+��9������&Q�������� �������#�������������������� ������� ����4���0����������$�=4��)���� ������$��4����)�����3@ �������#��������������!4��#�������!������������� �� #���
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
��������#��#����4�
� "�8�������#��#��������#���#�������������!������������� �7��������������
� �)�������=4���#�����#��#�+
� �������� �������#��#�������7������� ��������������)������� ��������#������
� ���������!����)�����#��#��0��!�!�)������������'�2���������<�'��� ������� 3�
� ����2��� 4� ������#��#�0������������������� 4� ������#��#3
� �#���� �����#��#�
� '����!��#��������� ��!)� 4�����������#��#�� ���������� �����0������������� �������������)3���������#�#����� �������#��#���
��
IBM Haifa Research Lab – Event Processing
IBM Haifa Research Lab – Event Processing © 2008 IBM Corporation
'����� ���������)������+
� ��� ���������)�����4��!������������������������������������������� ������0����7������74�#������#���� ����� ������R3�
� ������ �������������� �0����)���� �����$��������� �����3�������5 ��������� 6 �� �4��� �������������)����8�� !4��������������7�)@ ��#�7������� ���������7��#
� �������������� ����������������!� ��� � ��0����!4�������4����������#� �##��7�����������4�4��3
� '�����#��� ��������S ����$������!��$���������$������������T���#4��������7�����#���������������!��������������4�� ���$���#�7�����#�����#��#��