awips2/ncep/gov.noaa.nws.ncep.edex.plugin.idft/res/spring/idft-ingest.xml
Richard Peter 449692aeff Issue #2368: Update JMS routing to set message persistence and durability at the config level
Former-commit-id: a5a7816b98 [formerly 5111debc92 [formerly 9ac3d2ddbeee7265b9b7879fcc6efcee95281872]]
Former-commit-id: 5111debc92
Former-commit-id: b803359eb4
2013-09-15 13:44:17 -05:00

64 lines
No EOL
2.2 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-3.1.xsd
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">
<bean id="idftDecoder" class="gov.noaa.nws.ncep.edex.plugin.idft.decoder.IdftDecoder">
<constructor-arg ref="idftPluginName" />
</bean>
<bean id="idftSeparator" class="gov.noaa.nws.ncep.edex.plugin.idft.decoder.IdftSeparator" />
<bean id="idftDistRegistry" factory-bean="distributionSrv"
factory-method="register">
<constructor-arg value="idft" />
<constructor-arg value="jms-dist:queue:Ingest.idft" />
</bean>
<bean id="idftCamelRegistered" factory-bean="contextManager"
factory-method="register" depends-on="persistCamelRegistered">
<constructor-arg ref="idft-camel"/>
</bean>
<camelContext id="idft-camel" xmlns="http://camel.apache.org/schema/spring"
errorHandlerRef="errorHandler"
autoStartup="false">
<endpoint id="idftFileEndpoint"
uri="file:${edex.home}/data/sbn/idft?noop=true&amp;idempotent=false" />
<route id="idftFileConsumerRoute"> <from ref="idftFileEndpoint" /> <bean
ref="fileToString" /> <setHeader headerName="pluginName"> <constant>idft</constant>
</setHeader> <to uri="jms-durable:queue:Ingest.idft" /> </route>
<!-- Begin idft routes -->
<route id="idftIngestRoute">
<from uri="jms-durable:queue:Ingest.idft" />
<setHeader headerName="pluginName">
<constant>idft</constant>
</setHeader>
<doTry>
<pipeline>
<bean ref="stringToFile" />
<split streaming="true">
<method bean="idftSeparator" method="separate" />
<doTry>
<pipeline>
<bean ref="idftDecoder" method="decode" />
<to uri="direct-vm:indexAlert" />
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
<to uri="log:idft?level=ERROR" />
</doCatch>
</doTry>
</split>
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
<to uri="log:airmet?level=ERROR" />
</doCatch>
</doTry>
</route>
</camelContext>
</beans>