Oracle® CEP Administrator's Guide Release 11gR1 (11.1.1) Part Number E14300-02 |
|
|
View PDF |
This section contains information on the following subjects:
Section 1.3, "Understanding Oracle CEP Server Configuration"
Section 1.4, "Understanding Oracle CEP Server Administration Tools"
Section 1.5, "Understanding Oracle CEP Server Administration Tasks"
An Oracle CEP server consists of logically related resources and services to which you deploy Oracle CEP applications. Services include:
Security—security services such as SSL, password stores, and authentication and authorization providers.
Jetty—HTTP server.
Java Management Extensions (JMX)—to provide programmatic access to Oracle CEP server and application behavior.
JDBC datasources—to access relational databases to store events for event record and playback, to access a table as an event source for Oracle CQL queries, and to join a table in EPL queries.
HTTP publish-subscribe server—to push event messages to subscribed clients such as the Oracle CEP Visualizer and your own Web 2.0 applications.
logging—to support monitoring and troubleshooting server and application operation.
All the files that apply to a server are contained in a single server directory. The main configuration file for the server is called config.xml
—this is where you configure the server's services and specify to which domain the server belongs. For more information, see Section 1.3.1, "Oracle CEP Server Configuration Files".
An Oracle CEP domain is the management unit of a set of one or more servers. There are two types of domain:
Standalone-server domain—A domain that contains a single server. This is the type of domain created by default by the Configuration Wizard and is the starting point for a multi-server domain.
For more information, see Chapter 2, "Administrating Oracle CEP Standalone-Server Domains".
Multi-server domain—A domain that contains two or more servers that share the same multicast address and port and share a security provider. Multi-server domains enable high availability for Oracle CEP applications. When you deploy an application to a multi-server domain, the application is replicated to each server in the domain.
The servers in a multi-server domain can be located on the same computer or on separate computers; what ties the servers together in a multi-server domain is that they have the same multicast address and port and belong to the same domain, all of which are configured in the server's config.xml
file.
For more information, see Chapter 3, "Administrating Oracle CEP Multi-Server Domains".
Figure 1-1 shows a state diagram for the Oracle CEP server lifecycle. In this diagram, the state names (STARTING
, RUNNING
, and SHUTTING_DOWN
) correspond to the ServerRuntimeMBean
method getState()
return values. These states are specific to Oracle CEP; they are not OSGi bundle states.
Figure 1-1 Oracle CEP Server Lifecycle State Diagram
Note:
For information on Oracle CEP application lifecycle, see "Oracle CEP Application Lifecycle" in the Oracle CEP IDE Developer's Guide for Eclipse.This section describes the lifecycle of an application deployed to Oracle CEP and the sequence of com.bea.wlevs.ede.api
API callbacks. The lifecycle description is broken down into actions that a user performs, including:
This information explains how Oracle CEP manages an application's lifecycle so that you can better use the lifecycle APIs in your application. For a description of these APIs (such as RunnableBean
and SuspendableBean
), see:
"Oracle CEP APIs" in the Oracle CEP IDE Developer's Guide for Eclipse
After you start the Oracle CEP server, it performs the following actions:
Starts core engine bundles.
Starts Oracle CEP bundles.
Registers MBeans.
Oracle CEP server state is now STARTING
.
Starts application bundles.
Oracle CEP server state is now RUNNING
.
After you shutdown the Oracle CEP server, it performs the following actions:
Oracle CEP server state is SHUTTING_DOWN
.
Unregister ServerRuntimeMBean
.
Oracle CEP server ceases to have a state.
Shuts down Oracle CEP bundles.
Shuts down application bundles.
Shuts down core engine bundles.
Oracle CEP server configuration falls into two categories:
configuring a server
configuring the applications you deploy to a server
For each configuration category, you can perform the configuration task:
Statically: by editing an XML file manually.
Using this approach, you must restart the server or redeploy the application after making a change.
Dynamically: by manipulating management beans (MBeans) using Oracle CEP Visualizer, wlevs.Admin
command-line utility, or programmatically using JMX,
Using this approach, you do not have to restart the server or redeploy the application after making a change
You configure the server statically by:
Stopping the Oracle CEP server.
Editing the Oracle CEP server config.xml
file located in the server's domain directory
Starting the Oracle CEP server.
There are some server configuration tasks that you can only perform statically, such as configuring Jetty.
There are some server configuration tasks that you can perform dynamically using management beans (MBeans). In this case you do not have to manually stop and start the server for the changes to take effect.
You can dynamically configure Oracle CEP servers and applications using Oracle CEP Visualizer, wlevs.Admin
command line utility, or your own Java code using Oracle CEP standards-based interfaces that are fully compliant with JMX APIs (http://java.sun.com/javase/technologies/core/mntr-mgmt/javamanagement/
).
Typically, you statically configure an application when you initially create it, as described in Oracle CEP IDE Developer's Guide for Eclipse. In particular, you configure the event processing network (EPN) of the application by creating the EPN assembly file, and configure individual components of the application (adapters, channels, and processors) by creating their configuration files.
After you deploy an application, you can dynamically change its configuration, as well as the configuration of its individual components, by manipulating the MBeans that the Oracle CEP server automatically creates for the application and its components. A typical task is to dynamically configure the Oracle CQL rules for the processors of a deployed application. You do this using Oracle CEP Visualizer, wlevs.Admin command-line utility, or JMX.
For more information, see:
By default, the Configuration Wizard creates domains in the ORACLE_CEP_HOME
/user_projects/domains
directory, where ORACLE_CEP_HOME
refers to the Oracle CEP installation directory such as d:\oracle_cep
.
For example, d:\oracle_cep\user_projects\domains\my_domain
, where my_domain
is the a domain directory. Each Oracle CEP server you create in this domain will have a subdirectory in my_domain such as c:\oracle_cep\user_projects\domains\my_domain\server1
.
The following list describes the important files and directories of a server in a domain, relative to the server directory (such as c:\oracle_cep\user_projects\domains\my_domain\server1
):
deployments.xml
—XML file that contains the list of applications, packaged as OSGi bundles, that are currently deployed to the Oracle CEP instance of this domain. You never update this file manually to deploy applications, but rather, use the deployer tool.
startwlevs.cmd
—Command file used to start an instance of Oracle CEP. The UNIX equivalent is called startwlevs.sh
.
stopwlevs.cmd
—Command file used to stop an instance of Oracle CEP. The UNIX equivalent is called stopwlevs.sh
.
config/config.xml
—XML file that describes the services that have been configured for the Oracle CEP instance. Services include logging, debugging, Jetty Web Service, and JDBC data sources.
For more information, see Section 1.3.2, "Configuring an Oracle CEP Server by Manually Editing the config.xml File".
config/security*
—Files that configure security for the domain.
config/atnstore.txt
—File that lists the configured users and groups for this domain.
The most efficient, least error-prone way to configure an Oracle CEP server is to use one or more of the Oracle CEP administration tools as Section 1.4, "Understanding Oracle CEP Server Administration Tools" describes.
Optionally, you can perform Oracle CEP server configuration by manually editing the Oracle CEP server config.xml
file. For more information on the location of the Oracle CEP server config.xml
file, see Section 1.3.1, "Oracle CEP Server Configuration Files".
Caution:
If you update theconfig.xml
file manually to change the configuration of an Oracle CEP server, you must restart the server for the change to take effect.You can configure the following server objects and features using the config.xml
file (the referenced sections describe the exact elements you must add or update):
How the servers in a multi-server domain are configured together. This includes the multicast address and port, the groups, and so on.
See:
Security.
Jetty, an open-source, standards-based, full-featured Java Web Server.
JMX, required to use the Oracle CEP Visualizer, wlevs.Admin
utility, and Deployer utility
JDBC data source, used to connect to a relational database.
HTTP publish-subscribe server.
See Chapter 8, "Configuring HTTP Publish-Subscribe for Oracle CEP."
Logging and debugging properties of the server. By default, the log level is set to NOTICE
.
See Chapter 9, "Configuring Logging and Debugging for Oracle CEP."
Example 1-1 shows a sample config.xml
, from the ORACLE_CEP_HOME
/user_projects/domains/ocep_domain/defaultserver
template domain, shows how to configure some of these services.
Example 1-1 Sample Oracle CEP Server config.xml File
<?xml version="1.0" encoding="UTF-8"?> <!--Sample XML file generated by XMLSpy v2007 sp2 (http://www.altova.com)--> <n1:config xsi:schemaLocation="http://www.bea.com/ns/wlevs/config/server wlevs_server_config.xsd" xmlns:n1="http://www.bea.com/ns/wlevs/config/server" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <netio> <name>NetIO</name> <port>9002</port> </netio> <netio> <name>sslNetIo</name> <ssl-config-bean-name>sslConfig</ssl-config-bean-name> <port>9003</port> </netio> <work-manager> <name>JettyWorkManager</name> <min-threads-constraint>5</min-threads-constraint> <max-threads-constraint>10</max-threads-constraint> </work-manager> <jetty> <name>JettyServer</name> <network-io-name>NetIO</network-io-name> <work-manager-name>JettyWorkManager</work-manager-name> <secure-network-io-name>sslNetIo</secure-network-io-name> </jetty> <rmi> <name>RMI</name> <http-service-name>JettyServer</http-service-name> </rmi> <jndi-context> <name>JNDI</name> </jndi-context> <exported-jndi-context> <name>exportedJndi</name> <rmi-service-name>RMI</rmi-service-name> </exported-jndi-context> <jmx> <rmi-service-name>RMI</rmi-service-name> <jndi-service-name>JNDI</jndi-service-name> </jmx> <ssl> <name>sslConfig</name> <key-store>./ssl/evsidentity.jks</key-store> <key-store-pass> <password>{Salted-3DES}j4XEtuXmmvEl4M/NInwq0A==</password> </key-store-pass> <key-store-alias>evsidentity</key-store-alias> <key-manager-algorithm>SunX509</key-manager-algorithm> <ssl-protocol>TLS</ssl-protocol> <enforce-fips>false</enforce-fips> <need-client-auth>false</need-client-auth> </ssl> <http-pubsub> <name>pubsub</name> <path>/pubsub</path> <pub-sub-bean> <server-config> <name>/pubsub</name> <supported-transport> <types> <element>long-polling</element> </types> </supported-transport> <publish-without-connect-allowed>true</publish-without-connect-allowed> </server-config> <channels> <element> <channel-pattern>/evsmonitor</channel-pattern> </element> <element> <channel-pattern>/evsalert</channel-pattern> </element> <element> <channel-pattern>/evsdomainchange</channel-pattern> </element> </channels> </pub-sub-bean> </http-pubsub> <cluster> <server-name>productionServer</server-name> </cluster> <domain> <name>ocep_domain</name> </domain>
This section describes the various Oracle CEP server administration tools that you can use to administer Oracle CEP servers, domains, and applications.
You can administer Oracle CEP servers, domains, and applications using any of the following:
For more information, see:
Section 1.3, "Understanding Oracle CEP Server Configuration"
Section 1.5, "Understanding Oracle CEP Server Administration Tasks"
The Configuration Wizard is a Java application that you can invoke graphically to create and update Oracle CEP servers and domains.
For more information, see:
The Oracle CEP Visualizer is the Oracle CEP graphical administration console.
It is a Web 2.0 application that consumes data from Oracle CEP, displays it in a useful and intuitive way to system administrators and operators, and, for specified tasks, accepts data that is then passed back to Oracle CEP to change its configuration.
Using Oracle CEP Visualizer, you can perform a wide variety of Oracle CEP server, domain, and application administration tasks for existing Oracle CEP standalone server domains and Oracle CEP multi-server domains.
For more information, see "Overview of Visualizer" in the Oracle CEP Visualizer User's Guide.
The wlevs.Admin
command-line utility is a Java application that you can invoke locally or remotely to perform a wide variety of Oracle CEP server, domain, and application administration tasks.
For more information, see Appendix A, "wlevs.Admin Command-Line Reference".
The Deployer command-line utility is a Java application that you can invoke locally or remotely to perform application deployment and application administration tasks.
For more information, see Appendix B, "Deployer Command-Line Reference".
Oracle CEP provides a variety of command-line utilities that simplify security administration.
For more information, see Appendix C, "Security Utilities Command-Line Reference".
Using standards-based interfaces that are fully compliant with the Java Management Extensions (JMX) specification, you can perform a wide variety of Oracle CEP server, domain, and application administration tasks programatically using JMX and Oracle CEP MBeans.
For more information, see:
This section describes some of the important Oracle CEP server administration tasks, including:
Section 1.5.5, "Deploying Applications to Oracle CEP Servers"
Section 1.5.6, "Managing Oracle CEP Applications, Servers, and Domains"
The most important administration task is to create Oracle CEP servers and domains.
For more information, see:
Once you create an Oracle CEP server and domain, you can update it to change its configuration or group membership.
For more information, see:
Once you create an Oracle CEP server and domain, you must configure the various services they provide.
For more information, see:
After you have created an Oracle CEP domain along with at least a single server, you start a server instance so you can then deploy applications and begin running them. During upgrades and after some configuration changes, you must stop and start the Oracle CEP server.
For more information, see:
Once you have created and configured an Oracle CEP server and domain, you can deploy Oracle CEP applications to them.
For more information, see:
Section 2.5, "Deploying an Application to an Oracle CEP Standalone-Server Domain"
Section 3.8, "Deploying an Application to an Oracle CEP Multi-Server Domain"
"Overview of Creating Oracle CEP Applications" in the Oracle CEP IDE Developer's Guide for Eclipse.
Once you have deployed applications to an Oracle CEP server and domain, you must manage the application to perform tasks such as monitor its performance and perform upgrades.
For more information, see: