Refactored to use inheritance and separate logic where possible. Addressed comments. Change-Id: I9e62414cd83121575bdf99a3b47466a7585bedb6 Former-commit-id:909571ebca
[formerlye4be1f24e7
] [formerlydbba727f3d
] [formerly909571ebca
[formerlye4be1f24e7
] [formerlydbba727f3d
] [formerly17196b5dcd
[formerlydbba727f3d
[formerly 6e015b3f61c20635077d6e8271e9b763e5a32fe1]]]] Former-commit-id:17196b5dcd
Former-commit-id:b5fa843960
[formerlyff87317bd4
] [formerly f202d7fc11f48792bac7d10cbb20d9ba9077aa8f [formerly8b279966d1
]] Former-commit-id: b1349363c5b25965107de3827211c7bcc6b9e98b [formerlyb3fd8e5480
] Former-commit-id:de624d87d3
65 lines
No EOL
2.6 KiB
XML
65 lines
No EOL
2.6 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="convsigmetDecoder" class="gov.noaa.nws.ncep.edex.plugin.convsigmet.decoder.ConvSigmetDecoder">
|
|
<constructor-arg ref="convsigmetPluginName"/>
|
|
</bean>
|
|
|
|
<bean id="convsigmetSeparator" class="gov.noaa.nws.ncep.edex.plugin.convsigmet.decoder.ConvSigmetSeparator"/>
|
|
|
|
<bean id="convsigmetDistRegistry" factory-bean="distributionSrv"
|
|
factory-method="register">
|
|
<constructor-arg value="convsigmet" />
|
|
<constructor-arg value="jms-durable:queue:Ingest.convsigmet" />
|
|
</bean>
|
|
|
|
<camelContext id="convsigmet-camel"
|
|
xmlns="http://camel.apache.org/schema/spring"
|
|
errorHandlerRef="errorHandler">
|
|
<!--
|
|
<endpoint id="convsigmetFileEndpoint" uri="file:${edex.home}/data/sbn/convsigmet?noop=true&idempotent=false"/>
|
|
|
|
<route id="convsigmetFileConsumerRoute">
|
|
<from ref="convsigmetFileEndpoint"/>
|
|
<bean ref="fileToString" />
|
|
<setHeader headerName="pluginName">
|
|
<constant>convsigmet</constant>
|
|
</setHeader>
|
|
<to uri="jms-durable:queue:Ingest.convsigmet"/>
|
|
</route>
|
|
-->
|
|
|
|
<!-- Begin ConvSigmet routes -->
|
|
<route id="convsigmetIngestRoute">
|
|
<from uri="jms-durable:queue:Ingest.convsigmet"/>
|
|
<setHeader headerName="pluginName">
|
|
<constant>convsigmet</constant>
|
|
</setHeader>
|
|
<doTry>
|
|
<pipeline>
|
|
<bean ref="stringToFile" />
|
|
<split streaming="true">
|
|
<method bean="convsigmetSeparator" method="separate"/>
|
|
<doTry>
|
|
<pipeline>
|
|
<bean ref="convsigmetDecoder" method="decode"/>
|
|
<to uri="direct-vm:indexAlert"/>
|
|
</pipeline>
|
|
<doCatch>
|
|
<exception>java.lang.Throwable</exception>
|
|
<to uri="log:convsigmet?level=ERROR"/>
|
|
</doCatch>
|
|
</doTry>
|
|
</split>
|
|
</pipeline>
|
|
<doCatch>
|
|
<exception>java.lang.Throwable</exception>
|
|
<to uri="log:convsigmet?level=ERROR"/>
|
|
</doCatch>
|
|
</doTry>
|
|
</route>
|
|
</camelContext>
|
|
</beans> |