How to Create an Oracle CEP Multi-Server Domain With Default Groups Using Oracle Coherence

Administrating Multi-Server Domains With Oracle Coherence 6-5 In this procedure, assume you have created three servers: myServer1, myServer2, and myServer3. You want myServer1 to be a member of the selector group and myServer2 and myServer3 to be members of the strategy group. To create an Oracle CEP multi-server domain with custom groups using Oracle Coherence: 1. Create a domain that contains a single, initial server. See Chapter 3, Administrating Oracle CEP Standalone-Server Domains . 2. Add one or more servers to the domain using the Configuration Wizard. See Section 6.2, Updating an Oracle CEP Multi-Server Domain Using Oracle Coherence. 3. Configure all the servers in the multi-server domain by manually editing their config.xml files and adding a cluster element with specific information. To configure the servers in a multi-server domain using custom groups, update the config.xml file for each member server by adding if one does not already exist a groups child element of cluster and specifying the name of the group as the value of the groups element. The groups element can include more than one group name in the case that the server is a member of more than one group; separate multiple group names using commas. The groups element is optional; if a server configuration does not include one, then the server is a member of the default groups domain and singleton. For more information about the domain and singleton groups, see Section 5.2, Groups . Example 6–3 , Example 6–4 , and Example 6–5 show the relevant snippets of the config.xml file for each server. Example 6–3 Server Configuration File config.xml for myServer1 config domain Note: In this section it is assumed that you have already created a domain that contains a single server and that you want to add additional servers to the domain to make it a multi-server domain. See Chapter 3, Administrating Oracle CEP Standalone-Server Domains for details on creating a domain. Note: Even though the Configuration WizardWizard does not support adding new servers to a multi-server domain, one can use the Configuration Wizard to generate a new stand-alone server, and then manually update its configuration to join a multi-server domain. Note: When adding cluster element child elements, observe the correct element order as Section 5.5, Order of cluster Element Child Elements describes. 6-6 Oracle Complex Event Processing Administrators Guide namemyDomainname domain cluster server-namemyServer1server-name multicast-address239.255.0.1multicast-address enabledtrueenabled groupsselectorgroups cluster ... config Example 6–4 Server Configuration File config.xml for myServer2 config domain namemyDomainname domain cluster server-namemyServer2server-name multicast-address239.255.0.1multicast-address enabledtrueenabled groupsstrategygroups cluster ... config Example 6–5 Server Configuration File config.xml for myServer3 config domain namemyDomainname domain cluster server-namemyServer3server-name multicast-address239.255.0.1multicast-address enabledtrueenabled groupsstrategygroups cluster ... config 4. Optionally, override the default Oracle Coherence clustering configuration, if necessary. See Section 6.1.3, Configuring the Oracle Coherence Cluster . 5. Optionally, secure the messages that are shared between the servers in a domain by configuring encryption and digital signatures. See Section 6.3.1, How to Secure the Messages Sent Between Servers in a Multi-Server Domain Using Oracle Coherence . 6. To avoid a single point of failure, consider enabling Oracle CEP Visualizer on a small subset of n machines in the domain. See How to Start Oracle CEP Visualizer in a Multi-Server Domain in the Oracle Complex Event Processing Visualizer Users Guide. Administrating Multi-Server Domains With Oracle Coherence 6-7 7. Start all servers in your multi-server domain. See Section 6.5, Starting and Stopping an Oracle CEP Server in a Multi-Server Domain .

6.1.3 Configuring the Oracle Coherence Cluster

Oracle CEP leverages the native configuration provided by Oracle Coherence. You do this by packaging the following Oracle Coherence configuration file, with the indicated names, in the application bundle that uses the Oracle Coherence cache: ■ tangosol-coherence-override.xml—Oracle Coherence cluster configuration. See Section 6.1.3.1, The tangosol-coherence-override.xml File for information about this file as well as an example. When assembling your application, consider the following: ■ tangosol-coherence-override.xml is a global per-server file referred to as operational configuration in the Oracle Coherence documentation; put this file in the Oracle CEP server config directory. When you declare that a caching system uses the Oracle Coherence provider, be sure that all of the caches of this caching system also map to an Oracle Coherence configuration and not an Oracle CEP local configuration, or Oracle CEP throws an exception.

6.1.3.1 The tangosol-coherence-override.xml File

The tangosol-coherence-override.xml file configures Oracle Coherence clustering. The following sample shows a simple configuration. See the explanation after the sample for information about the sections in bold. ?xml version=1.0? coherence xml-override=tangosol-coherence-override.xml cluster-config member-identity cluster-namecom.bea.wlevs.example.providercluster-name member-identity ... coherence This configuration file is fairly standard. The main thing to note is that you should specify a cluster-name element to prevent Oracle Coherence from attempting to join existing Oracle Coherence clusters when Oracle CEP starts up; this can cause problems and sometimes even prevent Oracle CEP from starting. For detailed information about the tangosol-coherence-override.xml file, see Operational Override File tangosol-coherence-override.xml in the Oracle Coherence Developers Guide. Note: Enabling Oracle CEP Visualizer on a given Oracle CEP Server may impact the performance of the server depending on the Oracle CEP Visualizer workload.