25 Oracle Complex Event Processing

This chapter describes issues associated with Oracle Complex Event Processing (Oracle CEP). It includes the following topics:

25.1 General Issues and Workarounds

This section describes general issue and workarounds. It includes the following topics:

25.1.1 Deprecated API and Schemas

Table 25-1 lists Java API deprecated in 11g Release 1 (11.1.1) and the replacement API, if any.

Table 25-1 Deprecated Java API

Deprecated API Replacement API

com.bea.wlevs.ede.api.Stream

com.bea.wlevs.ede.api.EventChannel

com.bea.wlevs.ede.api.EventSender

com.bea.wlevs.ede.api.RelationSender

com.bea.wlevs.ede.api.StreamSender

com.bea.wlevs.ede.api.EventSink

com.bea.wlevs.ede.api.RelationSink

com.bea.wlevs.ede.api.StreamSink

com.bea.wlevs.ede.api.EventSource

com.bea.wlevs.ede.api.RelationSource

com.bea.wlevs.ede.api.StreamSource

com.bea.wlevs.management.configuration.StageMBean methods relating to event record and playback

com.bea.wlevs.management.configuration.RecordPlaybackMBean

com.bea.wlevs.management.configuration.StageMBean method getRecordPlaybackMBean returning RecordPlaybackMBean


Table 25-2 lists Oracle CEP schema deprecated in 11g Release 1 (11.1.1) and the replacement schema, if any.

Table 25-2 Deprecated Oracle CEP Schema

Deprecated Schema Deprecated in Assembly File? Deprecated in Component Configuration File? Replacement Schema

wlevs:stream

Yes

Yes

wlevs:channel

wlevs:metadata

Yes

N/A

wlevs:property

wlevs:function attribute epl-name

Yes

N/A

wlevs:function attribute function-name

wlevs:adapter attribute manageable

Yes

N/A

None.

wlevs:channel attribute manageable

Yes

N/A

None.

wlevs:adapter attribute monitoring

N/A

Yes

None.

wlevs:channel attribute monitoring

N/A

Yes

None.

wlevs:processor attribute monitoring

N/A

Yes

None.


25.1.2 Adapter Changes

The programming model for adapters has changed as follows:

Outbound Adapters

Adapters can now also be outbound; previously they were only inbound.

Lifecycle Callback Methods for Adapters

Spring tags for adapters now include attributes for setting lifecycle callback methods via the EPN assembly file.

Runnable Adapters

For adapters that want to run in a thread, their Java class should now implement com.bea.wlevs.ede.api.RunnableBean.

Adapter Factories

Programmers are no longer required to create an adapter factory when creating adapters. You only need to create an adapter factory if you want to share adapters among applications.

Publishing Adapter Providers

Adapter providers are factories for adapters that are published through the OSGi service registry.

Previously, the only way of advertising adapter providers was to use Spring-DM only, like this:

<osgi:service interface="com.bea.wlevs.ede.api.AdapterFactory" ref="myBean">
    <osgi:service-properties>
        <entry key="type" value="SocketAdapterType"/>
    </osgi:service-properties>
</osgi:service>

However, Spring-DM does not support exporting and importing an OSGi service in the same application so the above approach is deprecated.

Now, you should declare providers with the wlevs:factory tag like this:

<wlevs:factory provider-name="SocketAdapterType" ref="myBean">

This will work whether the adapters are in the same application or not.

Note that if your adapters and providers are collocated (both in the same application) using a provider is optional; you could just instantiate the adapter directly.

Failure to make this change may result in an application that fails to start and eventually times out.

StockTick Event Type Replaced by OracleStockTick

When using the loadgen adapter, note that the StockTick event is now named OracleStockTick.

25.1.3 New and Deprecated Options in the Deployer Tool

The -start and -stop commands of the Deployer tool have been deprecated.

When using the -install command to install an application, Oracle CEP automatically starts it after all internal initialization tasks have completed. Subsequently, if you stop and start the Oracle CEP server instance, the application is automatically stopped and started, respectively.

The Deployer tool has two new options: -suspend and -resume. Users should use -suspend to suspend a currently running application, and -resume for it to resume running.

"Deployer Command-Line Reference" in the Oracle CEP Administrator's Guide.

25.1.4 Changes in Management, Monitoring, and JMX

The management framework of Oracle CEP has been overhauled in this release.

Oracle CEP no longer supports the JRMP protocol. Instead, JMX clients must use the more secure MSA protocol for both local and remote access to the Oracle CEP JMX server. When you connect to the Oracle CEP JMX server that is running on localhost or on a remote host, you must always use the JMX URL service:jmx:msarmi://HOST-NAME:PORT/jndi/jmxconnector so that you are always using the MSA connector (where HOST-NAME is either localhost or the name of the remote host and PORT is the Oracle CEP server JNDI port).

For more information, see:

25.1.5 Using stopwlevs.sh With Multiple Servers on the Same Host

Included per bug 8417480.

Consider a scenario where you start two servers on the same host, for example, with server 1 listening on port 9002 and server 2 listening on port 9022. If you then use stopwlevs.sh in the server 1 domain directory, the server listening on port 9002 is stopped. If you then use stopwlevs.sh in the server 2 domain directory, the stop operation fails due to connection reset error.

Workaround: use the stopwlevs.sh command line argument -url or -listenPort to specify a port other than 9002.

25.1.6 Monitor Service may Underestimate Latency For Application-Timestamped Channels

The monitor service may underestimate the latency time of events that are being processed through the CQL processor when application-timestamped channels are being used and is-totally-ordered is not enabled.

25.1.7 Connecting to Oracle CEP Server Using JConsole may Throw Benign Null Pointer Exceptions

Included per bug 8515145.

When you connect to Oracle CEP server using JConsole (with or without the wlevsjconsole.sh script), JConsole may throw a java.lang.NullPointerException.

Workaround: click OK in the exception dialog box and proceed. The exception does not affect the JMX connection or Oracle CEP server.

25.1.8 Variable Duration Non-Event Detection is not Supported in This Release

Fixed duration non-event pattern detection is supported in 11g Release 1 (11.1.1). When you create a query for fixed duration non-event detection, you may use the DURATION clause with constant value and time unit, such as DURATION 5 SECONDS, or just a constant value such as DURATION 5.

Variable duration non-event pattern detection is not supported in 11g Release 1 (11.1.1). That is, you may not use the DURATION clause with an arbitrary arithmetic expression, such as DURATION c1+4.

Recurring non-event pattern detection is supported in 11g Release 1 (11.1.1) but only for the fixed duration case. That is, you may use a DURATION clause with a MULTIPLES OF clause but only for a duration that is a constant value.

25.1.9 JMSAdapterMBean Getter Methods for New Connection and User and Password

The following methods have been added to com.bea.wlevs.management.configuration.JMSAdapterMBean:

  • getConnectionUser

  • getConnectionPassword

  • getConnectionEncryptedPassword

The following attributes have been added to the wlevs_application_config.xsd element jms-adapter:

  • connection-user

  • connection-password

  • connection-encrypted-password

When Oracle CEP acquires the JNDI InitialContext, it uses the user and password (or encrypted-password) settings.

When Oracle CEP calls the createConnection method on the javax.jms.ConnectionFactory to create a connection to the JMS destination (JMS queue or topic), it uses the connection-user and connection-password (or connection-encrypted-password) settings, if configured. Otherwise, Oracle CEP uses the user and password (or encrypted-password) settings.

You can use the connection-user and connection-password (or connection-encrypted-password) settings in applications where one security provider is used for JNDI access and a separate security provider is used for JMS access.

25.2 Configuration Issues and Workarounds

This section describes configuration issues and their workarounds. It includes the following topics:

25.2.1 Accessing Signal Generation Dashboard With Firefox Version 3.0 on Windows

When accessing the signal generation example dashboard (at URL http://localhost:9002/signalgeneration/dashboard.html) using the Firefox browser version 3.0 on Windows, you will get an error when you click Start.

Workaround: use Internet Explorer version 7 to access the signal generation example dashboard.

25.2.2 VPN Software and Multicast Traffic

Active VPN software is known to have unpredictable behavior on multicast traffic. Additionally, having both Cisco VPN and Nortel VPN installed breaks multicast traffic.

25.2.3 Starting Oracle CEP Visualizer With Firefox

When using Oracle CEP Visualizer with the Firefox browser (version 3.0, SSL, and JDK 1.6), the first time you access a Oracle CEP Visualizer page it will render slowly, sometimes up to 30 seconds.

25.2.4 Uploading Files Using Oracle CEP Visualizer With Firefox and SSL

When using Oracle CEP Visualizer, you may get an error if you try to upload a file using the Firefox browser and SSL.

This is a known problem (http://bugs.adobe.com/jira/browse/FP-226) with Adobe Flex that affects Oracle CEP Visualizer.

25.2.5 A Channel Cannot be a Foreign Stage When Connected to an Oracle CQL Processor

If a channel is connected to an Oracle CQL processor, it cannot be a foreign stage.

25.2.6 Exceptions Thrown When Using Oracle CEP Visualizer with FireFox

When using Oracle CEP Visualizer with FireFox:

  • Do not set the Jetty scratch directory to a path with a space in it. Doing so will cause FileNotFoundException.

  • Ignore EOFException thrown on the server side; these exceptions will not cause client side failure.

25.2.7 Oracle CEP IDE for Eclipse is Incompatible With Required FireFox 3 Libraries on Linux

Included per bug 8514556.

The Oracle CEP IDE for Eclipse uses Eclipse 3.3, which is incompatible with required FireFox 3 libraries on Linux. In this case, Eclipse will crash on startup with a JVM core dump and error message like this:

# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x00bc80ac, pid=18044, tid=3086637584
#
# Java VM: Java HotSpot(TM) Client VM (11.3-b02 mixed mode, sharing
linux-x86)
# Problematic frame:
# C  [libc.so.6+0x710ac]  memcpy+0x1c
#
# An error report file with more information is saved as:
# /usr/local/bt/workspace/testruntime/eclipse/hs_err_pid18044.log 

Workaround: perform the following procedure.

  1. Change to the root user on your Linux machine.

  2. Prevent Eclipse from loading the libc.so library noted in the core dump error message:

    mv libc.so libc.so.orig
    

    Note:

    This will disable FireFox 3 on this machine. To use FireFox 3, you must change the name of this library back to libc.so.
  3. Follow the instructions outlined in the Eclipse Linux crash support Wiki page:

    http://wiki.eclipse.org/IRC_FAQ#I_just_installed_Eclipse_on_Linux.2C_but_it_does_not_start._What_is_the_problem.3F

    In particular, ensure that the JVM you are using with Eclipse is:

    • explicitly pointed to in the eclipse.ini file, and

    • JDK 1.6 or higher

25.2.8 Configuring Oracle CEP Native Clustering Using IPv6 on Linux

Included per bug 8548822.

When using Oracle CEP native clustering on Linux with IPv6, you may see an error like the one shown in Example 25-1 after restarting a member of a cluster.

Example 25-1 Oracle CEP Server Log evs4j Error

<Error> <evs4j> <BEA-2049005> <The cluster member 3 is considered to have failed>

Workaround: perform the following procedure:

  1. Using the editor of your choice, open the startwlevs.sh script for the affected Oracle CEP sever.

    The startwlevs.sh server start script is located in the server directory under the main domain directory. For example, the default server directory of the HelloWorld domain is located in ORACLE_CEP_HOME/ocep_11.1/samples/domains/helloworld_domain/defaultserver, where ORACLE_CEP_HOME refers to the main Oracle CEP installation directory, such as /oracle_cep.

  2. Edit the startwlevs.sh script to add the -Djava.net.preferIPv4Stack=true property to the java command line:

    "$JAVA_HOME/bin/java" $JVM_ARGS $DEBUG_ARGS -Djava.net.preferIPv4Stack=true  -Dwlevs.home="$USER_INSTALL_DIR" -Dbea.home="$BEA_HOME" -jar "${USER_INSTALL_DIR}/bin/wlevs.jar" $ARGS
    
  3. Save and close the startwlevs.sh script.

  4. Start the affected Oracle CEP server using the modified startwlevs.sh script.

25.2.9 Multi-Byte Characters are not Supported by loadgen

The loadgen utility supports only ASCII characters. It does not support multi-byte character sets.

25.2.10 Oracle CEP Server Will not Start if the Keystore and Private Key Passwords are Different

The passwords for the keystore and the alias for the SSL private key must be the same. If they are not, the Oracle CEP Server will not start.

25.2.11 Configuring Oracle CEP Server to use the Sun JVM

Typically, when you install Oracle CEP server, you configure Oracle CEP server to use the bundled JRockit SDK 1.6.0_05. Alternatively, you can configure Oracle CEP server to use a supported Sun Microsystems JDK.

How to configure Oracle CEP Server for use with the Sun JVM:

  1. Install the appropriate Sun JDK.

    For more information, see:

  2. Using the editor of your choice, open the setDomainEnv.sh or setDomainEnv.cmd script for the affected Oracle CEP sever.

    This script is located in the server directory under the main domain directory. For example, the default server directory of the HelloWorld domain is located in ORACLE_CEP_HOME/ocep_11.1/samples/domains/helloworld_domain/defaultserver, where ORACLE_CEP_HOME refers to the main Oracle CEP installation directory, such as /oracle_cep.

  3. Edit this script to set the JAVA_HOME variable to your JDK 1.6.0_11 installation:

    JAVA_HOME=/scratch/jdk/jdk_1.6.0_11
    
  4. Save and close the script.

  5. Using the editor of your choice, open the startwlevs.sh or startwlevs.cmd script for the affected Oracle CEP sever.

    This server start script is located in the server directory under the main domain directory. For example, the default server directory of the HelloWorld domain is located in ORACLE_CEP_HOME/ocep_11.1/samples/domains/helloworld_domain/defaultserver, where ORACLE_CEP_HOME refers to the main Oracle CEP installation directory, such as /oracle_cep.

  6. Edit this script to add the following properties to the JVM_ARGS variable:

    ...
    JVM_ARGS=-XX:+UnlockDiagnosticVMOptions -XX:+UnsyncloadClass -Xms512m
    ...
    
  7. Save and close the script.

  8. Start the affected Oracle CEP server using the modified startwlevs.sh or startwlevs.cmd script.

25.2.12 Eclipse 3.3 Fails to Start Up on Red Hat Linux 5.3

Eclipse 3.3 fails to start on Red Hat Linux 5.3.

To work around this issue, add the following to the eclipse.ini file:

 -Dorg.eclipse.swt.browser.XULRunnerPath=/usr/lib/xulrunner-1.9

This is not an issue in Eclipse 3.4 and higher.

25.2.13 Oracle CEP Applications as Web Service Provider Requires JDK 1.6.0_14 or Higher

To configure an Oracle CEP application as a Web service provider, you must use JDK 1.6.0_14 or above.

25.3 Documentation Errata

This section describes documentation errata. It includes the following topics:

25.3.1 Colt Aggregate Function Example Output Incomplete

"Functions: Colt Aggregate" in the Oracle CEP CQL Language Reference contains incomplete example output for the following functions:

  • AUTOCORRELATION

  • HARMONICMEAN

  • TRIMMEDMEAN

25.3.2 Installing Oracle CEP for Use With a Sun JVM

You can use Oracle CEP server with a supported Sun JVM. To do so:

  1. Install a supported Sun JVM.

    For more information, see:

  2. Install Oracle CEP as a custom install and select the supported Sun JVM:

  3. In each Oracle CEP domain directory, update the setDomainEnv and startwlevs scripts.

    For more information, see Section 25.3.3, "Configuring Oracle CEP for the Sun JDK on Linux".

25.3.2.1 Installing Oracle CEP in Graphical Mode

The Oracle CEP graphical installation program is self-explanatory, however, you can follow these steps for more information.

To install Oracle CEP in graphical mode:

  1. Log in to the Windows or UNIX computer on which you want to install Oracle CEP.

    Be sure you log in to the computer as the user that will be the main administrator of the Oracle CEP installation.

  2. Download the product distribution file for the platform on which you want to install Oracle CEP.

  3. Launch the installation program in graphical mode using the commands listed in the following table appropriate for your platform.

    Platform Instructions
    Windows Using Windows Explorer, double-click the appropriate installation program file from its download directory.
    Linux or Solaris Open a command window, change to the download directory, and enter these commands:
    prompt> chmod a+x filename
    prompt> ./filename
    

    In the preceding commands, filename is the name of the installation program specific to your platform (for more informaton, see http://www.oracle.com/technology/software/products/middleware/htdocs/111110_fmw.html.)

    If you want to create an installation log, use the -log=full_path_to_log_file option; for example:

    prompt> ./filename -log=C:\logs\server_install.log
    

    After the installation program has finished loading, you will see the standard Welcome window.

  4. Click Next.

  5. In the Choose Middleware Home Directory window, you can specify either an existing ORACLE_CEP_HOME directory or create a new one:

    1. To install into an existing ORACLE_CEP_HOME directory:

      • Select Use an Existing Middleware Home.

      • Select an existing ORACLE_CEP_HOME directory from the list on the right.

    2. To install into a new ORACLE_CEP_HOME directory:

      • Select Create a New Middleware Home.

      • Click the Browse button to browse your computer to select an existing directory or use the New Folder button to create a new directory and then select it.

      • Click Open.

    The ORACLE_CEP_HOME directory is the main installation directory for Oracle CEP, such as c:\oracle_cep. You can have one or many ORACLE_CEP_HOME directories on your computer, whichever suits your development and production environments best.

  6. Click Next.

  7. In the Choose Install Type window, you can choose one of the following options:

    1. To install all Oracle CEP components except the samples and use the Oracle JRockit JVM included with Oracle CEP:

      • Select Typical.

      • Click Next.

      • Proceed to step 10.

      The installer program checks to see if the ORACLE_CEP_HOME directory contains the version of JRockit required by this release of Oracle CEP:

      • If it finds the required JRockit installation, it does not install a new one.

      • If it does not find an appropriate JRockit installation, then the installer installs its own version in the ORACLE_CEP_HOME directory.

    2. To install all Oracle CEP components including the samples and select a previously installed Sun or platform-specific JVM (or use the Oracle JRockit JVM included with Oracle CEP):

      • Select Custom.

      • In the Choose Products and Components window, check the components you want to install, such as the product samples.

      • Click Next.

      Note:

      By default, the complete installation does not include the product samples. If you want to install the samples (recommended), choose the Custom option.

      If you want to use a Sun or platform-specific JVM, you must choose the Custom option.

      The installer program allows you to choose the JDK to use and to decide whether or not to install the Oracle JRockit JVM included with Oracle CEP.

  8. In the JDK Selection window, you can choose the JDK for the Oracle CEP server.

    Use the Browse button to select the Sun or platform-specific JDK you installed previously.

    If you do not want the installer to install the Oracle JRockit JVM included with Oracle CEP, uncheck this item.

  9. Click Next.

  10. In the Choose Product Installation Directories window, you can change the default name of the home directory of Oracle CEP, ocep_11.1.

    Although you can name this directory anything you want, Oracle recommends that you use the default name for clarity and standardization. For example, the documentation assumes that you install into the ocep_11.1 directory.

  11. Click Next.

  12. If you are installing on Windows, and you logged in as a user with Administrator privileges, then you will see the Choose Shortcut Location window where you can choose where you want the Start Menu folder to appear. The following table describes the options available:

    If you select . . . The following occurs . . .
    All Users Recommended. All users registered on the machine are provided with access to the installed software. Subsequently, if users without Administrator privileges use the Configuration Wizard from this installation to create domains, Start menu shortcuts to the domains are not created. In this case, users can manually create shortcuts in their local Start menu folders, if desired.
    Local user Other users registered on this machine will not have access to the Start menu entries for this installation.

    If you logged in as a user without Administrator privileges, the Start menu entries are created in your user's local Start menu folder.

  13. Click Next.

  14. The Installation Summary window shows the products and components you are about to install, along with the approximate size in MB. This window is for your information only; to change the components to be installed, use the Previous button to return to the appropriate window.

  15. Click Next.

    The installer program installs Oracle CEP. The Installation Complete window indicates that the product was installed successfully.

  16. Click Done to exit the program.

  17. Review the post-installation steps that Section 2.7, "Post-Installation Steps" in the Oracle CEP Getting Started describes.

25.3.2.2 Installing Oracle CEP in Console Mode

Console-mode installation is an interactive, text-based method for installing your software from the command line, on either a UNIX or Windows system.

When installing in console-mode, respond to the prompts in each section by entering the number associated with your choice or by pressing Enter to accept the default. To exit the installation process, enter exit (or x, for short) in response to any prompt. To review or change your selection, enter previous (or p, for short) at the prompt. To proceed to the following window, enter next (or n, for short).

Note:

In the following procedure, Windows conventions (such as back-slashes in pathnames) are used, for example, C:\oracle_cep\ocep_11.1. When entering pathnames on a UNIX system, be sure to use UNIX conventions, instead. For example, use forward slashes in pathnames, such as /oracle_cep/ocep_11.1.

To install Oracle CEP in graphical mode:

  1. Log in to the Windows or UNIX computer on which you want to install Oracle CEP.

    Be sure you log in to the computer as the user that will be the main administrator of the Oracle CEP installation.

  2. Download the product distribution file for the platform on which you want to install Oracle CEP.

  3. Launch the installation program in console mode using the commands listed in the following table appropriate for your platform.

    Platform Instructions
    Windows Open a command window, change to the download directory, and enter the following command:
    prompt> filename -mode=console
    

    In the preceding command, filename is the name of the installation program specific to your platform (for more information, see http://www.oracle.com/technology/software/products/middleware/htdocs/111110_fmw.html).

    If you want to create an installation log, use the -log=full_path_to_log_file option; for example:

    prompt> filename -mode=console -log=C:\logs\server_install.log
    
    Linux or Solaris Open a command window, change to the download directory, and enter these commands:
    prompt> chmod a+x filename
    prompt> ./filename -mode=console
    

    In the preceding commands, filename is the name of the installation program specific to your platform (for more information, see http://www.oracle.com/technology/software/products/middleware/htdocs/111110_fmw.html).

    If you want to create an installation log, use the -log=full_path_to_log_file option; for example:

    prompt> ./filename -mode=console -log=C:\logs\server_install.log
    

  4. At the Welcome prompt, type next (or n for short) or press Enter to continue with the installation process.

  5. In the Choose Middleware Home Directory window, you can specify either an existing ORACLE_CEP_HOME directory or create a new one:

    1. To install into an existing ORACLE_CEP_HOME directory:

      • Type the number of the existing ORACLE_CEP_HOME directory.

    2. To install into a new ORACLE_CEP_HOME directory:

      • Type 1 to create a new ORACLE_CEP_HOME directory.

      • The installation program guides you through the required steps to create the new ORACLE_CEP_HOME.

        Be sure to enter the full path of the ORACLE_CEP_HOME directory, for example C:\oracle_cep2.

        If you specify a directory that does not exist, the installation program creates it for you.

    The ORACLE_CEP_HOME directory is the main installation directory for Oracle CEP, such as c:\oracle_cep. You can have one or many ORACLE_CEP_HOME directories on your computer, whichever suits your development and production environments best.

  6. Confirm your choice for ORACLE_CEP_HOME directory and enter next (or n).

  7. In the Choose Install Type window, you can choose one of the following options:

    1. To install all Oracle CEP components except the samples and use the Oracle JRockit JVM included with Oracle CEP:

      • Type 1 to choose a Typical install.

      • Proceed to step 9.

      The installer program checks to see if the ORACLE_CEP_HOME directory contains the version of JRockit required by this release of Oracle CEP:

      • If it finds the required JRockit installation, it does not install a new one.

      • If it does not find an appropriate JRockit installation, then the installer installs its own version in the ORACLE_CEP_HOME directory.

    2. To install all Oracle CEP components including the samples and select a previously installed Sun or platform-specific JVM (or use the Oracle JRockit JVM included with Oracle CEP):

      • Type 2 to choose a Custom install.

      • In the Choose Components to Install window, enter the numbers in brackets to toggle the components you want to install, such as the samples. To toggle a selection in the list, types its number. When a check mark appears next to the option, the option is selected. To unselect the option, enter its number again to remove the check mark

      • Enter next (or n) when you have chosen the components.

      Note:

      By default, the complete installation does not include the product samples. If you want to install the samples (recommended), choose the Custom option.

      If you want to use a Sun or platform-specific JVM, you must choose the Custom option.

      The installer program allows you to choose the JDK to use and to decide whether or not to install the Oracle JRockit JVM included with Oracle CEP.

  8. In the JDK Selection window, you can choose the JDK for the Oracle CEP server:

    • To add a local JDK, select the Add Local JDK option (1).

      The installation program guides you through the required steps to add a local JDK.

      Be sure to enter the full path to the JDK directory, for example:

      C:\Program Files\Java\jdk1.6.0_14
      

      To add additional JDKs, select 1 again.

    • In the JDK Selection window, enter the numbers in brackets to toggle the JDKs you want. To toggle a selection in the list, types its number. When a check mark appears next to the option, the option is selected. To unselect the option, enter its number again to remove the check mark.

      If you do not want the installer to install the Oracle JRockit JVM included with Oracle CEP, uncheck this item.

    • Enter next (or n) when you have selected the local JDK.

  9. In the Choose Product Installation Directories window, you can change the default name of the home directory of Oracle CEP, ocep_11.1, by entering a new value.

    Although you can name this directory anything you want, Oracle recommends that you use the default name for clarity and standardization. For example, the documentation assumes that you install into the ocep_11.1 directory.

    Enter next (or n) when you are done.

  10. If you are installing on Windows, and you logged in as a user with Administrator privileges, then you will see the Choose Shortcut Location window where you can choose where you want the Start Menu folder to appear. The following table describes the options available:

    If you select . . . The following occurs . . .
    1 "All Users" Recommended. All users registered on the machine are provided with access to the installed software. Subsequently, if users without Administrator privileges use the Configuration Wizard from this installation to create domains, Start menu shortcuts to the domains are not created. In this case, users can manually create shortcuts in their local Start menu folders, if desired.
    2 "Local user" Other users registered on this machine will not have access to the Start menu entries for this installation.

    If you logged in as a user without Administrator privileges, the Start menu entries are created in your user's local Start menu folder.

    Enter the appropriate number.

  11. Enter next (or n) when you are done.

  12. The Installation Summary window shows the products and components you are about to install, along with the approximate size in MB. This window is for your information only; to change the components to be installed, type Previous to return to the appropriate window.

  13. Enter next (or n).

    The installer program installs Oracle CEP. The Installation Complete window indicates that the product was installed successfully.

  14. Type exit to exit the program.

  15. Review the post-installation steps that Section 2.7, "Post-Installation Steps" in the Oracle CEP Getting Started describes.

25.3.2.3 Installing Oracle CEP in Silent Mode

Silent-mode installation is a non-interactive method of installing your software that requires the use of an XML properties file for selecting installation options.

To install Oracle CEP in silent mode:

  1. Log in to the Windows or UNIX computer on which you want to install Oracle CEP.

    Be sure you log in to the computer as the user that will be the main administrator of the Oracle CEP installation.

  2. Download the product distribution file for the platform on which you want to install Oracle CEP.

  3. Create a silent.xml file that defines the configuration settings normally entered by a user during an interactive installation process.

    See Section 25.3.2.3.1, "Creating a silent.xml File for Silent-Mode Installation."

    Note:

    Incorrect entries in the silent.xml file can cause installation failures. To help you determine the cause of a failure, we recommend that you create a log file when you launch the installation program.
  4. Launch the installation program in silent mode using the commands in the following table appropriate for your platform.

    Platform Instructions
    Windows Open a command window, change to the download directory, and enter the following command:
    prompt> filename -mode=silent -silent_xml=path_to_xml_file
    

    In the preceding command, filename is the name of the installation program specific to your platform (for more information, see http://www.oracle.com/technology/software/products/middleware/htdocs/111110_fmw.html) and path_to_xml_file is the full pathname of the silent.xml template file you created in the preceding step.

    If you want to create an installation log, use the -log=full_path_to_log_file option; for example:

    prompt> filename -mode=silent -silent_xml=path_to_xml_file  -log=C:\logs\server_install.log
    
    Linux or Solaris Open a command window, change to the download directory, and enter these commands:
    prompt> chmod a+x filename
    prompt> ./filename -mode=silent -silent_xml=path_to_xml_file
    

    In the preceding commands, filename is the name of the installation program specific to your platform (for more information, see http://www.oracle.com/technology/software/products/middleware/htdocs/111110_fmw.html) and path_to_xml_file is the full pathname of the silent.xml template file you created in the preceding step.

    If you want to create an installation log, use the -log=full_path_to_log_file option; for example:

    prompt> ./filename -mode=silent -silent_xml=path_to_xml_file  -log=C:\logs\server_install.log
    

    An Oracle Installer window is displayed, indicating that the files are being extracted. No other prompt or text is displayed.

    The installation is complete when the Oracle Installer window disappears.

    See Section 25.3.2.3.3, "Returning Exit Codes to the Command Window" for getting information about the success or failure of the silent installation.

  5. Review the post-installation steps that Section 2.7, "Post-Installation Steps" in the Oracle CEP Getting Started describes.

25.3.2.3.1 Creating a silent.xml File for Silent-Mode Installation

When you install Oracle CEP in silent mode, the installation program uses an XML file (silent.xml) to determine which installation options should be implemented.

To create a silent.xml file for silent-mode installation:

  1. Using your favorite text editor, create an empty file called silent.xml on the computer on which you want to install Oracle CEP in silent mode.

  2. Copy the contents of the sample XML file, shown in Example 25-2, into your own silent.xml file.

    Example 25-2 Sample silent.xml File for Silent-Mode Installation

    <?xml version="1.0" encoding="UTF-8"?>
    <!-- Silent installer option: -mode=silent -silent_xml=C:\oracle\silent.xml -->
    <bea-installer> 
        <input-fields>
            <data-value name="BEAHOME"            value="C:\oracle_cep" />
            <data-value name="USER_INSTALL_DIR"   value="C:\oracle_cep\ocep_11.1" />
            <data-value name="INSTALL_SHORTCUT_IN_ALL_USERS_FOLDER"   value="yes"/>
            <data-value name="COMPONENT_PATHS" value="Oracle Complex Event Processing" />
        </input-fields> 
    </bea-installer>
    
  3. In the silent.xml file you just created, edit the values for the keywords shown in Table 25-3 to reflect your configuration.

    For example, if you want to install into the ORACLE_CEP_HOME directory e:\oracle_cep, update the corresponding <data-value> element as follows

    <data-value name="BEAHOME" value="e:\oracle_cep" />
    

    Table 25-3 Values for the silent.xml File

    For this data-value name... Enter the following value...
    BEAHOME
    

    The full pathname for the ORACLE_CEP_HOME directory of your choice.

    USER_INSTALL_DIR
    

    The full pathname for the directory where you want to install your Oracle CEP software.

    INSTALL_SHORTCUT_IN_ALL_USERS_FOLDER
    

    Windows only. Specify:

    • true, or yes, to create the shortcuts in the All Users folder.

    • false, or no, to create the shortcuts in the local users folder.

    The user performing the installation must have Administrator privileges to install the Start menu shortcuts in the All Users folder.

    The default value for this parameter, if you do not specify it, is true.

    COMPONENT_PATHS
    

    Specify the components and subcomponents of Oracle CEP you want to install on your system. Use the following values:

    • Oracle Complex Event Processing

    • Oracle Complex Event Processing/Event Server

    • Oracle Complex Event Processing/Event Server Samples

    For additional information about entering these values, see Section 25.3.2.3.2, "Guidelines for Component Selection."

    If you do not include the COMPONENT_PATHS data-value name in the silent.xml file, the complete Oracle CEP product is installed.

    LOCAL_JVMS

    Specify the local JDKs to be installed. Enter the full path of the JDKs to be installed, separated by the pipe symbol (|). Do not leave a space before or after the bar.

    Use this option to install Oracle CEP for use with a previously installed Sun or platform-specific JDK.

    BEA_BUNDLED_JVMS

    Specify the BEA-supplied JDKs to be installed. Enter the full path of the JDKs to be installed, separated by the pipe symbol (|). Do not leave a space before or after the bar.

    Use this option to install Oracle CEP for use with the Oracle JRockit JDK included in the Oracle CEP installer.


  4. Save the file in the directory of your choice.

25.3.2.3.2 Guidelines for Component Selection

Use the following guidelines when you specify values for the COMPONENT_PATHS data-value name:

  • When you specify a product component to be installed, all subcomponents that are installed by default in a complete installation are also installed. For example, the following entry installs both Oracle CEP and the samples:

    <data-value name="COMPONENT_PATHS" value="Oracle Complex Event Processing" />
    
  • To install multiple components or subcomponents, separate the components with a bar (|). Do not leave a space before or after the bar.

  • To specify subcomponents, you must specify a component/subcomponent combination for each entry. For example, to explicitly install Oracle CEP and the samples, enter the following line in the file:

    <data-value name="COMPONENT_PATHS" value="Oracle Complex Event Processing/Event Server|Oracle Complex Event Processing/Event Server Samples" />
    

    Note:

    Because this release of Oracle CEP includes only the server itself and samples, the preceding example is equivalent to the example in the first bullet.
25.3.2.3.3 Returning Exit Codes to the Command Window

When run in silent mode, the installation program generates exit codes that indicate the success or failure of the installation. These exit codes are shown in Table 25-4.

Table 25-4 Exit Codes

Code Description

0

Installation completed successfully

-1

Installation failed due to a fatal error

-2

Installation failed due to an internal XML parsing error


Example 25-3 provides a sample Windows command file that invokes the installation program in silent mode and echoes the exit codes to the command window from which the script is executed.

Example 25-3 Sample Windows Command File Displaying Silent-Mode Exit Codes

rem Execute the installer in silent mode
@echo off
ofm_ocep_generic_11.1.1.1.0_32_disk1_1of1.exe -mode=silent -silent_xml=C:\downloads\silent.xml -log=C:\logs\products_silent.log

@rem Return an exit code to indicate success or failure of installation
set exit_code=%ERRORLEVEL%

@echo.
@echo Exitcode=%exit_code%
@echo.
@echo Exit Code Key
@echo ---------------
@echo  0=Installation completed successfully
@echo -1=Installation failed due to a fatal error
@echo -2=Installation failed due to an internal XML parsing error
@echo.

25.3.3 Configuring Oracle CEP for the Sun JDK on Linux

Included per bug 9057227.

If you installed Oracle CEP for use with the Sun JDK on Linux, you must make changes to the setDomainEnv.sh and startwlevs.sh scripts in each Oracle CEP domain directory:

  1. Go to the domain directory.

    For example, ORACLE_CEP_HOME/user_projects/domains/ocep_domain/defaultserver

  2. Edit the setDomainEnv.sh script and add the following line:

    export DISPLAY=:0.0
    
  3. Edit the startwlevs.sh script and add -Djava.awt.headless=true to the java command line:

    "$JAVA_HOME/bin/java" $JVM_ARGS $DEBUG_ARGS -Djava.awt.headless=true -Dwlevs.home="$USER_INSTALL_DIR" -Dbea.home="$BEA_HOME"  -jar "${USER_INSTALL_DIR}/bin/wlevs.jar" $ARGS 
    

25.3.4 Oracle CEP IDE for Eclipse Support for Eclipse 3.5.0 (Galileo)

In this release, Oracle CEP IDE for Eclipse provides a plugin for Eclipse 3.5.0 (Galileo) as well as Eclipse 3.3.x (Europa). You may see minor differences between the Eclipse 3.5.0 user interface and screen captures in the Oracle CEP IDE Developer's Guide for Eclipse.

25.3.5 Connecting to the Oracle CEP Server Using Oracle JRockit Mission Control

Currently, Oracle JRockit Mission Control does not support the MSA RMI protocol. You cannot connect Oracle JRockit Mission Control to the Oracle CEP server using this protocol as "How to Connect to a Local or Remote Oracle CEP JMX Server Using JRockit Mission Control" in the Oracle CEP Administrator's Guide erroneously describes.

25.3.6 Connecting to the Oracle CEP Server Using JConsole

Included per bug 8515145.

The Oracle CEP Administrator's Guide describes how to connect to a local or remote Oracle CEP server using JConsole. This description should read as follows:

25.3.6.1 How to Connect to a Local or Remote Oracle CEP JMX Server Using JConsole With Security Enabled

You can use the wlevsjconsole script to connect to an Oracle CEP JMX server running on your local host or on a remote host to browse and manage Oracle CEP MBeans with the JDK jconsole.

This procedure describes how to use JConsole when the Oracle CEP server has security enabled. This is the default configuration and is recommended for production servers. Alternatively, you can connect to the JMX server with security disabled (see Section 25.3.6.2, "How to Connect to a Local or Remote Oracle CEP JMX Server Using JConsole With Security Disabled").

To connect to a local or remote Oracle CEP JMX server using JConsole with security enabled:

  1. Ensure that the local or remote Oracle CEP server is running.

  2. Open a command window and set your environment as described in "Setting Your Development Environment" in the Oracle CEP Getting Started.

  3. Launch jconsole using the wlevsjconsole.sh script located in the ORACLE_CEP_HOME/ocep_11.1/bin directory, where ORACLE_CEP_HOME refers to the directory in which you installed Oracle CEP (such as /oracle_home).

    1. To connect to a local Oracle CEP server, enter:

      prompt> wlevsjconsole.sh
      
    2. To connect to a remote Oracle CEP server, enter:

      prompt> wlevsjconsole.sh HOST-NAME:PORT
      

      Where HOST-NAME is the name of the remote host and PORT is the NetIO port as configured in the remote host's ORACLE_CEP_HOME/user_projects/domains/DOMAIN-NAME/defaultserver/config/config.xml file.

    The jconsole browser attempts to log into the JMX server and initially fails It displays a "Connection Failed: Retry?" dialog with a Connect and Cancel button.

  4. Click Cancel.

    The Jconsole New Connection dialog appears.

  5. Configure the New Connection dialog as Table 25-5 describes.

    Table 25-5 JConsole New Connection Attributes

    Attribute Description

    Remote Process

    Enter the following URL:

    service:jmx:msarmi://HOST-NAME:PORT/jndi/jmxconnector
    

    Where HOST-NAME is the name of the local or remote host and PORT is the NetIO port as configured in the remote host's ORACLE_CEP_HOME/user_projects/domains/DOMAIN-NAME/defaultserver/config/config.xml file (defualt 9002).

    Username

    Enter an Oracle CEP administration password.

    Default: wlevs.

    Password

    Enter the password for the Oracle CEP administration password you chose.

    Default: wlevs.


  6. Click Connect.

    The jconsole browser opens and provides access to Oracle CEP MBeans.

25.3.6.2 How to Connect to a Local or Remote Oracle CEP JMX Server Using JConsole With Security Disabled

You can use the wlevsjconsole script to connect to an Oracle CEP JMX server running on your local host or on a remote host to browse and manage Oracle CEP MBeans with the JDK jconsole.

This procedure describes how to use JConsole when the Oracle CEP server has security disabled. This is a common development configuration and is not recommended for production servers. Alternatively, you can connect to the JMX server with security enabled (see Section 25.3.6.1, "How to Connect to a Local or Remote Oracle CEP JMX Server Using JConsole With Security Enabled").

To connect to a local or remote Oracle CEP JMX server using JConsole with security disabled:

  1. Ensure that the local or remote Oracle CEP server is running with security disabled.

    For more information, see "Disabling Security" in the Oracle CEP Administrator's Guide.

  2. Open a command window and set your environment as described in "Setting Your Development Environment" in the Oracle CEP Getting Started.

  3. Launch jconsole using the wlevsjconsole.sh script located in the ORACLE_CEP_HOME/ocep_11.1/bin directory, where ORACLE_CEP_HOME refers to the directory in which you installed Oracle CEP (such as /oracle_home).

    1. To connect to a local Oracle CEP server, enter:

      prompt> wlevsjconsole.sg
      
    2. To connect to a remote Oracle CEP server, enter:

      prompt> wlevsjconsole.sh HOST-NAME:PORT
      

      Where HOST-NAME is the name of the remote host and PORT is the NetIO port as configured in the remote host's ORACLE_CEP_HOME/user_projects/domains/DOMAIN-NAME/defaultserver/config/config.xml file.

    The script automatically connects to the JMX server and the jconsole browser opens and provides access to Oracle CEP MBeans.

25.3.7 How to Implement a User-Defined Single-Row Function

Included per bug 9227529.

Example 13-1, "MyMod.java User-Defined Single-Row Function", in the Oracle CEP CQL Language Reference, is incorrect. Currently, it reads as follows:

package com.bea.wlevs.example.function;

public class MyMod {
    public Object execute(Object[] args) {
        int arg0 = ((Integer)args[0]).intValue();
        int arg1 = ((Integer)args[1]).intValue();
        return new Integer(arg0 % arg1);
    }
}

It should read as follows:

package com.bea.wlevs.example.function;

public class MyMod {
    public Object execute(int arg0, int arg1) {
        return new Integer(arg0 % arg1);
    }
}