| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108 |
- <?xml version="1.0" encoding="UTF-8"?>
- <beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
- xmlns:p="http://www.springframework.org/schema/p" xmlns:tx="http://www.springframework.org/schema/tx"
- xmlns:context="http://www.springframework.org/schema/context"
- xmlns:websocket="http://www.springframework.org/schema/websocket"
- xmlns:task="http://www.springframework.org/schema/task"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
- http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.1.xsd
- http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.1.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
- http://www.springframework.org/schema/websocket http://www.springframework.org/schema/websocket/spring-websocket.xsd
- http://www.springframework.org/schema/task
- http://www.springframework.org/schema/task/spring-task-3.1.xsd">
- <bean id="propertyConfigurer"
- class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
- <property name="locations">
- <list>
- <value>classpath*:config.properties</value>
- <value>classpath*:jdbc.properties</value>
- </list>
- </property>
- </bean>
- <!-- 不扫描带有@Controller注解的类。因为这些类已经随容器启动时,在rest-servlet中扫描过一遍了 交给springMVC
- 扫描实例化 -->
- <context:component-scan base-package="com.loygra.mooring">
- <context:exclude-filter type="annotation"
- expression="org.springframework.stereotype.Controller" />
- </context:component-scan>
- <!-- task任务扫描注解 -->
- <task:annotation-driven />
- <!-- 对标注@Transaction注解的Bean进行事务管理 -->
- <tx:annotation-driven transaction-manager="txManager" />
- <!-- ********** http任务执行线程池 start ************* -->
- <bean id="taskExecutor"
- class="org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor">
- <property name="corePoolSize" value="2" />
- <property name="maxPoolSize" value="5" />
- <property name="queueCapacity" value="6" />
- <property name="keepAliveSeconds" value="2000" />
- <property name="rejectedExecutionHandler">
- <bean class="java.util.concurrent.ThreadPoolExecutor$CallerRunsPolicy" />
- </property>
- </bean>
- <!-- ********** http任务执行线程池 end ************* -->
- <bean id="velocityEngine"
- class="org.springframework.ui.velocity.VelocityEngineFactoryBean">
- <property name="velocityProperties">
- <props>
- <prop key="resource.loader">file</prop>
- <prop key="file.resource.loader.class">org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader
- </prop>
- <prop key="file.resource.loader.cache">false</prop>
- <prop key="file.resource.loader.modificationCheckInterval">3</prop>
- <prop key="input.encoding">UTF-8</prop>
- <prop key="output.encoding">UTF-8</prop>
- </props>
- </property>
- </bean>
- <bean id="javaMailSender" class="org.springframework.mail.javamail.JavaMailSenderImpl">
- <property name="host">
- <value>${mail.host}</value>
- </property>
- <property name="port">
- <value>${mail.port}</value>
- </property>
- <property name="javaMailProperties">
- <props>
- <prop key="mail.smtp.auth">${mail.smtp.auth}</prop>
- <prop key="mail.smtp.timeout">${mail.smtp.timeout}</prop>
- </props>
- </property>
- <property name="username">
- <value>${mail.username}</value>
- </property>
- <property name="password">
- <value>${mail.password}</value>
- </property>
- </bean>
-
- <!-- websocket -->
- <bean id="websocket" class="com.loygra.mooring.websocket.WebsocketEndPoint"/>
- <websocket:handlers>
- <websocket:mapping path="/websocket" handler="websocket"/>
- <websocket:handshake-interceptors>
- <bean class="com.loygra.mooring.websocket.HandshakeInterceptor"/>
- </websocket:handshake-interceptors>
- </websocket:handlers>
-
-
- <bean id="msaapiService" class="com.yuanxd.tools.hscbdt.HscbdtServiceFactory" factory-method="create"/>
-
- <bean id="nauticalService" class="com.jsjty.xtong.service.NauticalService"></bean>
-
- <import resource="rest-jdbc.xml" />
-
- <import resource="rest-ehcache.xml"/>
- <!-- <bean id="applicationContext" class="com.loygra.mooring.util.SpringApplicationContext"
- /> -->
- </beans>
|