Download Developing Applications for Event Processing with Oracle Stream

Transcript
Configure High Availability Quality of Service
<wlevs:adapter id="myHaInputAdapter" provider="ha-inbound" >
</wlevs:adapter>
<wlevs:channel id="channel1" event-type="StockTick">
<wlevs:listener ref="processor1" />
<wlevs:source ref="myHaInputAdapter"/>
</wlevs:channel>
5. Configure your Oracle Stream Explorer application EPN assembly file to add an
Oracle Stream Explorer high availability correlating output adapter as shown.
• Add a wlevs:adapter element with provider set to ha-correlating after
channel channel2.
• Update the wlevs:listener element in channel channel2 to reference the
ha-correlating adapter by its id.
• Add a wlevs:listener element to the ha-correlating adapter that
references the regular output adapter JMSOutboundAdapter.
<wlevs:event-type-repository>
<wlevs:event-type type-name="StockTick">
<wlevs:properties>
<wlevs:property name="lastPrice" type="double" />
<wlevs:property name="symbol" type="char" />
</wlevs:properties>
</wlevs:event-type>
</wlevs:event-type-repository>
<wlevs:adapter id="JMSInboundAdapter" provider="jms-inbound">
<wlevs:listener ref="myHaInputAdapter"/>
</wlevs:adapter>
<wlevs:adapter id="myHaInputAdapter" provider="ha-inbound" >
</wlevs:adapter>
<wlevs:channel id="channel1" event-type="StockTick">
<wlevs:listener ref="processor1" />
<wlevs:source ref="myHaInputAdapter"/>
</wlevs:channel>
<wlevs:processor id="processor1">
<wlevs:listener ref="channel2" />
</wlevs:processor>
<wlevs:channel id="channel2" event-type="StockTick">
<wlevs:listener ref="myHaCorrelatingAdapter" />
</wlevs:channel>
<wlevs:adapter id="myHaCorrelatingAdapter" provider="ha-correlating" >
<wlevs:listener ref="JMSOutboundAdapter"/>
</wlevs:adapter>
<wlevs:adapter id="JMSOutboundAdapter" provider="jms-outbound">
</wlevs:adapter>
6. Configure the Oracle Stream Explorer high availability input adapter.
Consider using one of the following example configurations:
This example shows a high availability input adapter configuration using all
defaults. The mandatory key is based on all event properties and the event
property that the high availability input adapter assigns a time value to is an event
property named arrivalTime.
17-30 Developing Applications for Event Processing with Oracle Stream Explorer