|
|
@@ -1,101 +1,94 @@
|
|
1
|
1
|
<?xml version="1.0"?>
|
|
2
|
2
|
|
|
3
|
3
|
<beans xmlns="http://www.springframework.org/schema/beans"
|
|
|
4
|
+ xmlns:task="http://www.springframework.org/schema/task"
|
|
4
|
5
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
5
|
|
- xmlns:jaxws="http://cxf.apache.org/jaxws"
|
|
|
6
|
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
|
|
6
|
7
|
xsi:schemaLocation="http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
|
|
7
|
|
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
|
|
|
8
|
+ http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
|
|
|
9
|
+ http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task.xsd">
|
|
8
|
10
|
|
|
9
|
|
- <import resource="classpath:META-INF/cxf/cxf.xml"/>
|
|
|
11
|
+ <import resource="classpath:META-INF/cxf/cxf.xml"/>
|
|
10
|
12
|
|
|
11
|
13
|
|
|
12
|
|
- <!-- Handling report web service -->
|
|
|
14
|
+ <!-- Handling report web service -->
|
|
13
|
15
|
|
|
|
16
|
+ <jaxws:endpoint id="jax-ws.http" implementor="#handlingReportService" address="/RegisterEvent"/>
|
|
14
|
17
|
|
|
15
|
|
- <jaxws:endpoint id="jax-ws.http" implementor="#handlingReportService" address="/RegisterEvent"/>
|
|
|
18
|
+ <bean id="handlingReportService" class="se.citerus.dddsample.interfaces.handling.ws.HandlingReportServiceImpl">
|
|
|
19
|
+ <property name="applicationEvents" ref="applicationEvents"/>
|
|
|
20
|
+ </bean>
|
|
16
|
21
|
|
|
17
|
|
- <bean id="handlingReportService" class="se.citerus.dddsample.interfaces.handling.ws.HandlingReportServiceImpl">
|
|
18
|
|
- <property name="applicationEvents" ref="applicationEvents"/>
|
|
19
|
|
- </bean>
|
|
20
|
22
|
|
|
|
23
|
+ <!-- File upload directory scanner -->
|
|
21
|
24
|
|
|
22
|
|
- <!-- File upload directory scanner -->
|
|
|
25
|
+ <task:scheduled-tasks scheduler="myScheduler">
|
|
|
26
|
+ <task:scheduled ref="uploadDirectoryScanner" method="run" fixed-delay="5000"/>
|
|
|
27
|
+ </task:scheduled-tasks>
|
|
23
|
28
|
|
|
|
29
|
+ <task:scheduler id="myScheduler" pool-size="10"/>
|
|
24
|
30
|
|
|
25
|
|
- <!--bean id="scheduledTask" class="org.springframework.scheduling.timer.ScheduledTimerTask">
|
|
26
|
|
- <property name="period" value="5000"/>
|
|
27
|
|
- <property name="delay" value="5000"/>
|
|
28
|
|
- <property name="timerTask" ref="uploadDirectoryScanner"/>
|
|
29
|
|
- </bean-->
|
|
|
31
|
+ <bean id="uploadDirectoryScanner" class="se.citerus.dddsample.interfaces.handling.file.UploadDirectoryScanner">
|
|
|
32
|
+ <property name="uploadDirectory" value="/tmp/upload"/>
|
|
|
33
|
+ <property name="parseFailureDirectory" value="/tmp/failed"/>
|
|
|
34
|
+ <property name="applicationEvents" ref="applicationEvents"/>
|
|
|
35
|
+ </bean>
|
|
30
|
36
|
|
|
31
|
|
- <bean id="uploadDirectoryScanner" class="se.citerus.dddsample.interfaces.handling.file.UploadDirectoryScanner">
|
|
32
|
|
- <property name="uploadDirectory" value="/tmp/upload"/>
|
|
33
|
|
- <property name="parseFailureDirectory" value="/tmp/failed"/>
|
|
34
|
|
- <property name="applicationEvents" ref="applicationEvents"/>
|
|
35
|
|
- </bean>
|
|
|
37
|
+ <bean id="handlingReportConsumptionSupport" class="se.citerus.dddsample.interfaces.handling.HandlingReportParser"/>
|
|
36
|
38
|
|
|
37
|
|
- <bean id="handlingReportConsumptionSupport" class="se.citerus.dddsample.interfaces.handling.HandlingReportParser"/>
|
|
|
39
|
+ <!-- RMI exposed booking service facade, which operates in an open Hibernate session -->
|
|
38
|
40
|
|
|
39
|
|
- <!--bean id="timerFactory" class="org.springframework.scheduling.timer.TimerFactoryBean">
|
|
40
|
|
- <property name="scheduledTimerTasks">
|
|
41
|
|
- <list>
|
|
42
|
|
- <ref bean="scheduledTask"/>
|
|
43
|
|
- </list>
|
|
44
|
|
- </property>
|
|
45
|
|
- </bean-->
|
|
46
|
41
|
|
|
|
42
|
+ <bean id="hibernateInterceptor" class="org.springframework.orm.hibernate3.HibernateInterceptor">
|
|
|
43
|
+ <property name="sessionFactory" ref="sessionFactory"/>
|
|
|
44
|
+ </bean>
|
|
47
|
45
|
|
|
48
|
|
- <!-- RMI exposed booking service facade, which operates in an open Hibernate session -->
|
|
|
46
|
+ <bean id="bookingServiceFacade" class="org.springframework.aop.framework.ProxyFactoryBean">
|
|
|
47
|
+ <property name="target" ref="bookingServiceFacadeTarget"/>
|
|
|
48
|
+ <property name="interceptorNames">
|
|
|
49
|
+ <list>
|
|
|
50
|
+ <value>hibernateInterceptor</value>
|
|
|
51
|
+ </list>
|
|
|
52
|
+ </property>
|
|
|
53
|
+ </bean>
|
|
49
|
54
|
|
|
|
55
|
+ <bean id="bookingServiceFacadeTarget"
|
|
|
56
|
+ class="se.citerus.dddsample.interfaces.booking.facade.internal.BookingServiceFacadeImpl">
|
|
|
57
|
+ <property name="bookingService" ref="bookingService"/>
|
|
|
58
|
+ <property name="cargoRepository" ref="cargoRepository"/>
|
|
|
59
|
+ <property name="locationRepository" ref="locationRepository"/>
|
|
|
60
|
+ <property name="voyageRepository" ref="voyageRepository"/>
|
|
|
61
|
+ </bean>
|
|
50
|
62
|
|
|
51
|
|
- <bean id="hibernateInterceptor" class="org.springframework.orm.hibernate3.HibernateInterceptor">
|
|
52
|
|
- <property name="sessionFactory" ref="sessionFactory"/>
|
|
53
|
|
- </bean>
|
|
|
63
|
+ <bean class="org.springframework.remoting.rmi.RmiServiceExporter">
|
|
|
64
|
+ <property name="serviceInterface" value="se.citerus.dddsample.interfaces.booking.facade.BookingServiceFacade"/>
|
|
|
65
|
+ <property name="service" ref="bookingServiceFacade"/>
|
|
|
66
|
+ <property name="serviceName" value="BookingService"/>
|
|
|
67
|
+ </bean>
|
|
54
|
68
|
|
|
55
|
|
- <bean id="bookingServiceFacade" class="org.springframework.aop.framework.ProxyFactoryBean">
|
|
56
|
|
- <property name="target" ref="bookingServiceFacadeTarget"/>
|
|
57
|
|
- <property name="interceptorNames">
|
|
58
|
|
- <list>
|
|
59
|
|
- <value>hibernateInterceptor</value>
|
|
60
|
|
- </list>
|
|
61
|
|
- </property>
|
|
62
|
|
- </bean>
|
|
63
|
69
|
|
|
64
|
|
- <bean id="bookingServiceFacadeTarget" class="se.citerus.dddsample.interfaces.booking.facade.internal.BookingServiceFacadeImpl">
|
|
65
|
|
- <property name="bookingService" ref="bookingService"/>
|
|
66
|
|
- <property name="cargoRepository" ref="cargoRepository"/>
|
|
67
|
|
- <property name="locationRepository" ref="locationRepository"/>
|
|
68
|
|
- <property name="voyageRepository" ref="voyageRepository"/>
|
|
69
|
|
- </bean>
|
|
70
|
|
-
|
|
71
|
|
- <bean class="org.springframework.remoting.rmi.RmiServiceExporter">
|
|
72
|
|
- <property name="serviceInterface" value="se.citerus.dddsample.interfaces.booking.facade.BookingServiceFacade"/>
|
|
73
|
|
- <property name="service" ref="bookingServiceFacade"/>
|
|
74
|
|
- <property name="serviceName" value="BookingService"/>
|
|
75
|
|
- </bean>
|
|
|
70
|
+ <!-- Tracking web application support -->
|
|
76
|
71
|
|
|
77
|
72
|
|
|
78
|
|
- <!-- Tracking web application support -->
|
|
|
73
|
+ <bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver">
|
|
|
74
|
+ <property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/>
|
|
|
75
|
+ <property name="prefix" value="/WEB-INF/jsp/pub/"/>
|
|
|
76
|
+ <property name="suffix" value=".jsp"/>
|
|
|
77
|
+ <property name="requestContextAttribute" value="rc"/>
|
|
|
78
|
+ <property name="cache" value="false"/>
|
|
|
79
|
+ </bean>
|
|
79
|
80
|
|
|
|
81
|
+ <bean id="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
|
|
|
82
|
+ <property name="basename" value="messages"/>
|
|
|
83
|
+ </bean>
|
|
80
|
84
|
|
|
81
|
|
- <bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver">
|
|
82
|
|
- <property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/>
|
|
83
|
|
- <property name="prefix" value="/WEB-INF/jsp/pub/"/>
|
|
84
|
|
- <property name="suffix" value=".jsp"/>
|
|
85
|
|
- <property name="requestContextAttribute" value="rc"/>
|
|
86
|
|
- <property name="cache" value="false"/>
|
|
87
|
|
- </bean>
|
|
|
85
|
+ <bean id="localeResolver" class="org.springframework.web.servlet.i18n.FixedLocaleResolver">
|
|
|
86
|
+ <property name="defaultLocale" value="en"/>
|
|
|
87
|
+ </bean>
|
|
88
|
88
|
|
|
89
|
|
- <bean id="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
|
|
90
|
|
- <property name="basename" value="messages"/>
|
|
91
|
|
- </bean>
|
|
92
|
|
-
|
|
93
|
|
- <bean id="localeResolver" class="org.springframework.web.servlet.i18n.FixedLocaleResolver">
|
|
94
|
|
- <property name="defaultLocale" value="en"/>
|
|
95
|
|
- </bean>
|
|
96
|
|
-
|
|
97
|
|
- <bean id="openSessionInViewInterceptor" class="org.springframework.orm.hibernate3.support.OpenSessionInViewInterceptor">
|
|
98
|
|
- <property name="sessionFactory" ref="sessionFactory"/>
|
|
99
|
|
- </bean>
|
|
|
89
|
+ <bean id="openSessionInViewInterceptor"
|
|
|
90
|
+ class="org.springframework.orm.hibernate3.support.OpenSessionInViewInterceptor">
|
|
|
91
|
+ <property name="sessionFactory" ref="sessionFactory"/>
|
|
|
92
|
+ </bean>
|
|
100
|
93
|
|
|
101
|
94
|
</beans>
|