Scalability Using the ActiveActiveGroupBean

B Oracle CEP Schemas B-1 B Oracle CEP Schemas This section contains information on the following subjects: ■ Appendix B.1, EPN Assembly Schema spring-wlevs-v11_1_1_3.xsd ■ Appendix B.2, Component Configuration Schema wlevs_application_config.xsd ■ Appendix B.3, Deployment Schema deployment.xsd ■ Appendix B.4, Server Configuration Schema wlevs_server_config.xsd B.1 EPN Assembly Schema spring-wlevs-v11_1_1_3.xsd You use the EPN assembly file to declare the components that make up your Oracle CEP application and how they are connected to each other, or in other words, the event processing network. The EPN assembly file is an extension of the standard Spring context file. You also use the file to register the Java classes that implement the adapter and POJO components of your application, register the event types that you use throughout your application and EPL rules, and reference in your environment the Oracle CEP-specific services. The spring-wlevs-v11_1_1_3.xsd file describes the structure of EPN assembly files. This schema file is located in the ORACLE_CEP_HOME\ocep_11.1\xsd directory, where ORACLE_CEP_HOME is the main Oracle CEP installation directory, such as d:\oracle_cep. For more information, see Appendix C, Schema Reference: EPN Assembly spring-wlevs-v11_1_1_3.xsd . B.1.1 Example EPN Assembly File The following XML file shows the EPN assembly file for the HelloWorld example: ?xml version=1.0 encoding=UTF-8? beans xmlns=http:www.springframework.orgschemabeans xmlns:xsi=http:www.w3.org2001XMLSchema-instance xmlns:osgi=http:www.springframework.orgschemaosgi xmlns:wlevs=http:www.bea.comnswlevsspring xsi:schemaLocation= http:www.springframework.orgschemabeans http:www.springframework.orgschemabeansspring-beans.xsd http:www.springframework.orgschemaosgi http:www.springframework.orgschemaosgispring-osgi.xsd http:www.bea.comnswlevsspring http:www.bea.comnswlevsspringspring-wlevs-v11_1_1_3.xsd wlevs:event-type-repository B-2 Oracle Complex Event Processing Developers Guide wlevs:event-type type-name=HelloWorldEvent wlevs:classcom.bea.wlevs.event.example.helloworld.HelloWorldEventwlevs:class wlevs:event-type wlevs:event-type-repository -- Adapter can be created from a local class, without having to go through a adapter factory -- wlevs:adapter id=helloworldAdapter class=com.bea.wlevs.adapter.example.helloworld.HelloWorldAdapter wlevs:instance-property name=message value=HelloWorld - the current time is: wlevs:adapter wlevs:channel id=helloworldInputChannel event-type=HelloWorldEvent wlevs:listener ref=helloworldProcessor wlevs:source ref=helloworldAdapter wlevs:channel -- The default processor for Oracle CEP 11.0.0.0 is CQL -- wlevs:processor id=helloworldProcessor wlevs:channel id=helloworldOutputChannel event-type=HelloWorldEvent advertise=true wlevs:listener bean class=com.bea.wlevs.example.helloworld.HelloWorldBean wlevs:listener wlevs:source ref=helloworldProcessor wlevs:channel beans B.2 Component Configuration Schema wlevs_application_config.xsd An Oracle CEP application contains one or more component configuration files in its META-INFwlevs directory. You use component configuration files to override the default configuration for Oracle CEP components such as adapters, channels, and processors. The wlevs_application_config.xsd schema file describes the structure of component configuration files. This XSD schema imports the following schemas: ■ wlevs_base_config.xsd ■ wlevs_eventstore_config.xsd ■ wlevs_diagnostic_config.xsd These schema files are located in the ORACLE_CEP_HOME\ocep_11.1\xsd directory, where ORACLE_CEP_HOME is the main Oracle CEP installation directory, such as d:\oracle_cep. For more information, see Appendix D, Schema Reference: Component Configuration wlevs_application_config.xsd . B.2.1 Example Component Configuration File The following example shows the component configuration file for the HelloWorld sample application: ?xml version=1.0 encoding=UTF-8?n1:config xmlns:n1=http:www.bea.comnswlevsconfigapplication xmlns:xsi=http:www.w3.org2001XMLSchema-instance processor namehelloworldProcessorname rules query id=helloworldRule [CDATA[ select from helloworldInputChannel [Now] ]]