Getting started with Oracle 11g Complex Event Processing (CEP)

Installation starts with downloading and extracting the correct software of CEP download page

After downloading version 11.1.1.3.0 and extracting the archive file i got the following surprise

[root@weblogic11g downloads]# ll
total 807172
-rw-r--r-- 1 root root 369308535 May 25 09:27 ofm_ocep_linux_11.1.1.3.0_32_disk1_1of1.zip
-rwxr-xr-x 1 root root 371602691 Apr 20 19:18 ofm_ocep_linux_11.1.3.0.0_32_disk1_1of1.bin

notice the differen version numbers ’11.1.1.3.0′ of the archive file and the 11.1.3.0.0 of the binary file. But never the less you have the version 11.1.3 although the archive file suggests a different version.

After extracting the archive file grant execute rights on the file before starting

chmod +x ofm_ocep_linux_11.1.3.0.0_32_disk1_1of1.bin
export DISPLAY=lt-tarem:0.0
./ofm_ocep_linux_11.1.3.0.0_32_disk1_1of1.bin

Installation

I have Xming running on my windows desktop to recieve the xwindow from the server. This enables me to work in the graphical mode instead of showing the text base installation steps.
Splash screen

Welcome screen

I select ‘Use an exsitings Middlware Home’ for the CEP installation

I select here custom so i can install the samples to so show the working of CEP

I select here the Event Server Samples

For the existing Middlware home i have already a JDK so i specify the SUN SDK available on the server

As a last step you specify the Product Installation Directory

That’s all you need to specify because now you will get a ‘Installation Summary’

And the installation is completed

Starting the sample HelloWorld
After installation you can start a sample by running the startwlevs.sh script in the samples directory:

$ORACLE_HOME/ocep_11.1/samples/domains/helloworld_domain/defaultserver
./startwlevs.sh

when you see the following log the CEP is up and running:

Message: HelloWorld - the current time is:12:10:32 PM

Now you would like to know what’s happening. To understand what the HelloWorld sample is doing you can read the online documentation CEP HelloWorld. After that I wanted to see the code and make some changes to understand better the working of the sample.

Using Ecplise editor to edit the sources

I have started eclipse from the server using the following ssh command:

export DISPLAY=lt-tarem:0.0
cd $ORACLE_HOME/oepe_11gR1PS2/
./eclipse &

Keep in mind that eclipse is running on the server but the window is presented on the client. So in my case i have a windows machine but the path that i specify are of the server.

You can open now directly the sample code but Oracle has developed a plugin for Eclipse to help developing CEP projects. I first installed the plugin by following in Chapter 2.2 of the ‘Complex Event Processing Developer’s Guide’. I encounter a step 7 the choice of CEP Tools depening on my Eclipse version.

With the current installation i have Eclipse 3.5 so i selected the bottom one and i continued the installation steps. After completing the wizard you need to keep an eye on a popup window to restart Eclipse. This is needed to avoid strange behavior of the plugin.

After installing the plugin i wanted to have the sample code in a Eclipse project so i can nicly edit and deploy the CEP app. To do this i followed the steps to create a Oracle CEP Project specified in Chapter 3.2 of the Complex Event Processing Developer’s Guide. As a project directory i specified the sample directory of HelloWorld. The wizard includes automatically the sources already available on disk so i can directly edit the sample.

Now you will have something like this in Eclipse:

Links

Popularity: 39% [?]

Share this Post:
Digg Google Bookmarks reddit Mixx StumbleUpon Technorati Yahoo! Buzz DesignFloat Delicious BlinkList Furl

No Responses to “Getting started with Oracle 11g Complex Event Processing (CEP)”

Leave a Reply:

Name (required):
Mail (will not be published) (required):
Website:
Comment (required):
XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>