awips2/edexOsgi/com.raytheon.uf.edex.datadelivery.event/res/spring/event-datadelivery-ingest.xml
Benjamin Phillippe 3cc6978718 Issue #1802 Fixes related to DD transaction refactor
Change-Id: Ia2a7a4ce990d424ed1e365bd7003fd2ab8630fd1

Former-commit-id: 30be5ce6f9 [formerly 115dc12790] [formerly 2a14245dce [formerly 393a469e2f65894a6dd5b58c1431c3d727951eda]]
Former-commit-id: 2a14245dce
Former-commit-id: b0010de8ff
2013-03-27 17:12:52 -05:00

52 lines
No EOL
2 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="notificationHandler"
class="com.raytheon.uf.edex.datadelivery.event.handler.NotificationHandler">
<constructor-arg type="java.lang.String"
value="jms-generic:topic:notify.msg?destinationResolver=#qpidDurableResolver" />
<property name="notificationDao" ref="notificationDao" />
</bean>
<bean
class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
<property name="staticMethod"
value="com.raytheon.uf.common.event.EventBus.register" />
<property name="arguments">
<list>
<ref bean="notificationHandler" />
</list>
</property>
</bean>
<!-- verify text product info for site, spawns in separate thread to not
delay start up -->
<bean id="notificationPurge"
class="com.raytheon.uf.edex.datadelivery.event.notification.NotificationPurge"
depends-on="ddEventRegister" />
<bean id="noitfyCamelRegistered" factory-bean="contextManager"
factory-method="register" depends-on="persistCamelRegistered">
<constructor-arg ref="ddNotify-camel" />
</bean>
<camelContext id="ddNotify-camel" xmlns="http://camel.apache.org/schema/spring"
errorHandlerRef="errorHandler" autoStartup="false">
<route id="notificationPurgeRoute">
<from uri="timer://notifiyPurge?period=60s" />
<doTry>
<bean ref="notificationPurge" method="purge" />
<doCatch>
<exception>java.lang.Throwable</exception>
<to
uri="log:purge?level=ERROR&amp;showBody=false&amp;showCaughtException=true&amp;showStackTrace=true" />
</doCatch>
</doTry>
</route>
</camelContext>
</beans>