A footnote to the streamSQL paper

 
Thread Tools Search this Thread
Special Forums News, Links, Events and Announcements Complex Event Processing RSS News A footnote to the streamSQL paper
# 1  
Old 09-08-2008
A footnote to the streamSQL paper

2008-09-08T22:50:00.008+03:00

Image The comment that my good friend Claudi (AKA Pattern Storm) made in the complexevents forummade me curious to actually read this paper; reading it I had the uncomfortable feeling that since people insist to use a language style that implies type of thinking about event processing, and this creates semantic problems which they try to solve by use the same type of thinking, with more complicated constructs.


I'll use one simple example taken from the paper, which they had to deal with semantic problems that were caused by the way the language semantics.


The scenario (translated to my language - without the "streams") -- Events are reported about cars that move through some segment of the road; each event consists of



There are also simultaneous events, i.e. several events that happen in the same time unit (what ever the time granularity is). The inputs are events of this type, the output is - for each event, generate a derived event that include the original attributes of the events and the average speed of cars in the same time unit. If you want to see the types of problems that the SQL implementators see in this simple example, read the streamsql paper. Instead of discussing SQL, I would like to show an alternative way to think about the same problem.

The slide below shows an alternative way to think about this problem - this is a very simple EPN (Event Processing Network) which has two functional agents, one producer (e.g. an event emitter that create events from video stream produced by a camera that looks at the road) and one consumer (whoever wants to see the output events)..






Image
The two agents work under the same temporal context (it can be spatio-temporal if we also want to group by road segment) - in this case, a temporal context is opened and closed every beginning and end of 1 time unit.

  • The raw event is called "car position event" and it goes to both agents.
  • The first agent is an aggregator which calculates (incrementally) the average, since it is bounded to the context, the average is of events from the same time unit, at the end of the time unit it produces a single event "speed-average-event" with the structure

  • The second agent is a "pattern detector" which takes two input events - the "car position event" again, and the derived event "speed-average-event"; the pattern that need to be identified is AND, and the "speed-average-event" for that agent has a consumption policy of "reuse" (which means that if an event can be used for multiple patterns). The agent produces a derived event - for each AND pattern that consists of the "output-event" whose structure is:



This EPN does not involve "streams" - the thinking is "event oriented" and it attempts to provide natural thinking about event processing functionality.

Comments:

1. This is rather simple example, can also be solved by putting the average speed event on a global state (or event store/database) and then enrich it back - but the event-oriented is closer to the spirit of the original example which work on streams.

2. Aggregator and pattern detector are type of agents, there are some (not many) more types. Typically, an event processing network consist of multiple types of agents.

3. "Pattern Storm" claims that stream SQL ignore causality. One can view the relation between input events and output events of the same agent as a causality relation (he is using another scenario from the paper), and this can be set while defining the EPN.

One general comment (not related to this posting) - to "anonymous" - I'll gladly answer your question if you'll send it back and identify yourself. I don't publish anonymous comments.

I can post the solution to the rest of the examples in the stream SQL paper if anybody is interested...



Source...
Login or Register to Ask a Question

Previous Thread | Next Thread

7 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How to check if printer is out of paper using perl script ?

Hello, I need to chack if the printer is out of paper, and send message to operator. I need to do this from perl script. The printer have mechanism to check if it have paper. However, the cups does not report "printer out of paper" when I remove the paper, and try to print. Is there any... (1 Reply)
Discussion started by: +Yan
1 Replies

2. AIX

Print Paper Size always A3 instead of A4

RICOH MPC4501 via AIX PrintServer is only printing on A3, even though its A4 contents. Similar Printer on same AIX PrintServer is printing correct though. What you think issue with first printer? AIX V6.1 (1 Reply)
Discussion started by: panchpan
1 Replies

3. HP-UX

Setting printer paper length using unix commands

Hi Guys, I have been trying to resolve a printing problem but nothing works out . I have an Epson LQ 680 (dot matrix printer) . I need to print a file . The paper length should be 34 .Left margin should be 5. I have tried the following things after researching from the man pages. pr -t... (24 Replies)
Discussion started by: Kar1234
24 Replies

4. UNIX for Dummies Questions & Answers

Rock Paper Scissors

I'm trying to create this game in Unix. This is what I have so far: echo "Player one: Choose (R)ock, (P)aper (S)cissors" stty -echo read Pone case $Pone in R) echo "Good Choice! Let's see what Player two chooses.";; P) echo "Good Choice! Let's see what Player two chooses.";; S) echo... (5 Replies)
Discussion started by: gpro
5 Replies

5. Shell Programming and Scripting

Research paper library

menu should look at least like the following:- RESEARCH PAPER LIBRARY - Main Menu 0 : EXIT this program 1 : EDIT menu 2 : REPORTS Menu Enter your choice> program should check for invalid choice and display error message and re-display the main-menu. If EDIT is... (1 Reply)
Discussion started by: SHakur_BIG
1 Replies

6. Solaris

Printing spits out paper!!!

Hello again.. Here's my problem: i've got uses who print on a epson 1170 dot printer from a solaris server (SunOS ss5 5.3 Generic_101318-70 sun4m sparc) Normally they print out data of an informix database. The file is about 30 pages long. I had to modify the lp command as follows (lpbase... (1 Reply)
Discussion started by: penguin-friend
1 Replies

7. UNIX for Dummies Questions & Answers

Research paper

I am doing a "research" paper for school and i'm having a hard time finding accurate information. I am supposed to choose three differant versions of unix, give a brief explination of each, tell why there each differant from each other. I have found a ton of web sites but the information is so vast... (1 Reply)
Discussion started by: pantsusan
1 Replies
Login or Register to Ask a Question