awips2/ncep/gov.noaa.nws.ncep.edex.plugin.ncscat/res/spring/ncscat-ingest.xml
root 9f19e3f712 Initial revision of AWIPS2 11.9.0-7p5
Former-commit-id: 64fa9254b946eae7e61bbc3f513b7c3696c4f54f
2012-01-06 08:55:05 -06:00

76 lines
No EOL
2.6 KiB
XML

<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:amq="http://activemq.apache.org/schema/core"
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-2.0.xsd
http://activemq.apache.org/schema/core http://activemq.apache.org/schema/core/activemq-core.xsd
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">
<bean id="ncscatDao" class="gov.noaa.nws.ncep.common.dataplugin.ncscat.dao.NcscatDao">
<constructor-arg ref="ncscatPluginName"/>
</bean>
<bean id="ncscatDecoder" class="gov.noaa.nws.ncep.edex.plugin.ncscat.decoder.NcscatDecoder">
<constructor-arg ref="ncscatPluginName"/>
</bean>
<bean id="ncscatDistRegistry" factory-bean="distributionSrv"
factory-method="register">
<constructor-arg value="ncscat" />
<constructor-arg value="jms-dist:queue:Ingest.ncscat" />
</bean>
<bean id="ncscatCamelRegistered" factory-bean="contextManager"
factory-method="register" depends-on="persistCamelRegistered">
<constructor-arg ref="ncscat-camel"/>
</bean>
<camelContext id="ncscat-camel"
xmlns="http://camel.apache.org/schema/spring"
errorHandlerRef="errorHandler"
autoStartup="false">
<endpoint id="ncscatFileEndpoint" uri="file:${edex.home}/data/sbn/ncscat??noop=true&amp;idempotent=false" />
<!-- Begin Ncscat routes -->
<route id="ncscatFileConsumerRoute">
<from ref="ncscatFileEndpoint" />
<bean ref="fileToString" />
<setHeader headerName="pluginName">
<constant>ncscat</constant>
</setHeader>
<to uri="jms-generic:queue:Ingest.Ncscat" />
</route>
<route id="ncscatIngestRoute">
<from uri="jms-generic:queue:Ingest.Ncscat" />
<!-- <setHeader headerName="pluginName">
<constant>ncscat</constant>
</setHeader>-->
<doTry>
<pipeline>
<bean ref="stringToFile" />
<doTry>
<pipeline>
<!--
need to replace the method decode with decodeNcscatInputFile
<bean ref="ncscatDecoder" method="decode" /> -->
<bean ref="ncscatDecoder" method="decodeNcscatInputFile" />
<to uri="directvm:persistIndexAlert" />
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
<to uri="log:ncscat?level=ERROR&amp;showBody=false" />
</doCatch>
</doTry>
</pipeline>
<doCatch>
<exception>java.lang.Throwable</exception>
<to uri="log:ncscat?level=ERROR&amp;showBody=false" />
</doCatch>
</doTry>
<!-- bean ref="processUtil" method="delete" /-->
</route>
</camelContext>
</beans>