awips2/edexOsgi/com.raytheon.uf.edex.plugin.bufrncwf/res/spring/bufrncwf-ingest.xml
2018-06-20 17:39:08 -06:00

52 lines
No EOL
2.1 KiB
XML

<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://camel.apache.org/schema/spring
http://camel.apache.org/schema/spring/camel-spring.xsd">
<bean id="bufrncwfDecoder" class="com.raytheon.uf.edex.plugin.bufrncwf.BUFRncwfDecoder">
<constructor-arg ref="bufrncwfPluginName" />
</bean>
<bean id="bufrncwfDistRegistry" factory-bean="distributionSrv"
factory-method="register">
<constructor-arg ref="bufrncwfPluginName" />
<constructor-arg value="jms-durable:queue:Ingest.bufrncwf"/>
</bean>
<camelContext id="bufrncwf-camel"
xmlns="http://camel.apache.org/schema/spring"
errorHandlerRef="errorHandler">
<!--
<endpoint id="bufrncwfFileEndpoint" uri="file:${edex.home}/data/sbn/bufrncwf?noop=true&amp;idempotent=false" />
<route id="bufrncwfFileConsumerRoute">
<from ref="bufrncwfFileEndpoint" />
<bean ref="fileToString" />
<setHeader headerName="pluginName">
<constant>bufrncwf</constant>
</setHeader>
<to uri="jms-durable:queue:Ingest.bufrncwf" />
</route>
-->
<!-- Begin bufrncwf routes -->
<route id="bufrncwfIngestRoute">
<from uri="jms-durable:queue:Ingest.bufrncwf"/>
<setHeader headerName="pluginName">
<constant>bufrncwf</constant>
</setHeader>
<doTry>
<pipeline>
<bean ref="stringToFile" />
<bean ref="bufrncwfDecoder" method="decode" />
<to uri="direct-vm:persistIndexAlert" />
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
<to uri="log:bufrncwf?level=ERROR"/>
</doCatch>
</doTry>
</route>
</camelContext>
</beans>