Sponsored Content
Special Forums News, Links, Events and Announcements Complex Event Processing RSS News On state processing and event processing Post 302281486 by Linux Bot on Thursday 29th of January 2009 02:40:08 AM
Old 01-29-2009
On state processing and event processing

2009-01-29T08:51:00.006+02:00
Image
Yesterday, I got visited by my (now- Ex) Master student Elad Margalit, about his thesis regarding dynamic setting of traffic light policies I have written before. For some strange reason he decided that I deserve a gift for his graduation so he brought me a "flip clock" that looks like this. Strangely enough it switches the labels to show the correct time, all people who somehow got to my office yesterday thought it is a cool gadget, and it is now located in front of my eyes.

Today's topic is some echo to the discussion started by my friend and ex-IBM colleague Claudi AKA patternstorm on the forum in the complexevents site. Claudi has defined state as a sequence of events, while several others answered that this is not really the definition.

Before getting to definition, there was also very concrete motivation that Claudi mentioned -- if we equate state to "sequence of transitions" than state processing becomes a kind of event processing. I think that it is important to discuss this statement.

While state is not exactly a sequence of transitions, it is true that the value represented by the state can be reconstructed if we apply the series of transitions on an initial state, and considering that the initial transition is null and the first transition creates the state, we can obtain all information as part of series of transitions.

Let's take a simple example. The state represents the value of my balance in the bank checking account. The transitions start from a one that opens this account, going through deposits, withdrawals, commissions of the bank etc.. I have opened my current checking account in 1984. Assuming that I would like to process this state, such as getting an alert everytime that my account balance becomes negative (unlike the USA, in Israel overdraft is a common practice). I can make it an event processing activity by taking all transition from 1984 and reconstruct the state with each new transition, however, this is not an efficient way to do it, first I'll need to keep all the historical transitions forever, second, it is much more cost-effective to maintain the balance as an entity, and process it.

State processing and event processing are complementary, in states processing we are processing the snapshot of the present time, while in event processing we process the history of transitions. If I want to get alert on overdraft -- this is state processing, If a compliance officer looking for money laundering suspect is seeking if three deposits with more than $10,000 each were done to my account within a single week, he is doing event processing. In reality we need both, but each of them has other techniques for its cost-effective processing.

More on this topic -- later.



Source...
 

We Also Found This Discussion For You

1. Virtualization and Cloud Computing

Cloud Event Processing vs Event Cloud Processing?

vincent 01-20-2009 05:51 AM Interesting to see the huge interest in Cloud Computing. David Luckham’s complexevents.com just referenced one of several recent Infoworld articles and blogs that attempt to define the term. Another compares the buzz to past excitements - remember Application Service... (0 Replies)
Discussion started by: Linux Bot
0 Replies
kstat_queue(9F) 					   Kernel Functions for Drivers 					   kstat_queue(9F)

NAME
kstat_queue, kstat_waitq_enter, kstat_waitq_exit, kstat_runq_enter, kstat_runq_exit, kstat_waitq_to_runq, kstat_runq_back_to_waitq - update I/O kstat statistics SYNOPSIS
#include <sys/types.h> #include <sys/kstat.h> void kstat_waitq_enter(kstat_io_t *kiop); void kstat_waitq_exit(kstat_io_t *kiop); void kstat_runq_enter(kstat_io_t *kiop); void kstat_runq_exit(kstat_io_t *kiop); void kstat_waitq_to_runq(kstat_io_t *kiop); void kstat_runq_back_to_waitq(kstat_io_t *kiop); INTERFACE LEVEL
Solaris DDI specific (Solaris DDI) PARAMETERS
kiop Pointer to a kstat_io(9S) structure. DESCRIPTION
A large number of I/O subsystems have at least two basic "lists" (or queues) of transactions they manage: one for transactions that have been accepted for processing but for which processing has yet to begin, and one for transactions which are actively being processed (but not done). For this reason, two cumulative time statistics are kept: wait (pre-service) time, and run (service) time. The kstat_queue() family of functions manage these times based on the transitions between the driver wait queue and run queue. kstat_waitq_enter() kstat_waitq_enter() should be called when a request arrives and is placed into a pre-service state (such as just prior to calling disksort(9F)). kstat_waitq_exit() kstat_waitq_exit() should be used when a request is removed from its pre-service state. (such as just prior to calling the driver's start routine). kstat_runq_enter() kstat_runq_enter() is also called when a request is placed in its service state (just prior to calling the driver's start routine, but after kstat_waitq_exit()). kstat_runq_exit() kstat_runq_exit() is used when a request is removed from its service state (just prior to calling biodone(9F)). kstat_waitq_to_runq() kstat_waitq_to_runq() transitions a request from the wait queue to the run queue. This is useful wherever the driver would have normally done a kstat_waitq_exit() followed by a call to kstat_runq_enter(). kstat_runq_back_to_waitq() kstat_runq_back_to_waitq() transitions a request from the run queue back to the wait queue. This may be nec- essary in some cases (write throttling is an example). RETURN VALUES
None. CONTEXT
kstat_create() can be called from user or kernel context. WARNINGS
These transitions must be protected by holding the kstat's ks_lock, and must be completely accurate (all transitions are recorded). Forget- ting a transition may, for example, make an idle disk appear 100% busy. SEE ALSO
biodone(9F), disksort(9F), kstat_create(9F), kstat_delete(9F), kstat_named_init(9F), kstat(9S), kstat_io(9S) Writing Device Drivers SunOS 5.11 4 Apr 1994 kstat_queue(9F)
All times are GMT -4. The time now is 05:29 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy