ossean/match_program/bin/resources/applicationContext.xml

38 lines
1.8 KiB
XML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?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:context="http://www.springframework.org/schema/context"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-3.0.xsd">
<context:annotation-config />
<!-- c3p0连接池配置 -->
<bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource">
<!-- 用户名 -->
<property name="user" value="trustie" />
<!-- 用户密码 -->
<property name="password" value="1234" />
<property name="driverClass" value="com.mysql.jdbc.Driver" />
<property name="jdbcUrl"
value="jdbc:mysql://192.168.80.130:3306/ossean_production?useUnicode=true&amp;characterEncoding=utf-8" />
<!--连接池中保留的最大连接数。默认值: 15 -->
<property name="maxPoolSize" value="10" />
<!-- 连接池中保留的最小连接数默认为3 -->
<property name="minPoolSize" value="5" />
<!-- 初始化连接池中的连接数取值应在minPoolSize与maxPoolSize之间默认为3 -->
<property name="initialPoolSize" value="5" />
<!--最大空闲时间60秒内未使用则连接被丢弃。若为0则永不丢弃。默认值: 0 -->
<property name="maxIdleTime" value='60' />
<property name="maxStatements" value='100' />
<property name="maxStatementsPerConnection" value='20' />
</bean>
<!--context:component-scan base-package="net.trustie.webmagic.dao"/ -->
</beans>