C3P0数据连接池的配置文件c3p0-config.xml

<c3p0-config>
    
    <default-config>
        
        <property name="driverClass">com.mysql.jdbc.Driverproperty>
        <property name="jdbcUrl">jdbc:mysql://127.0.0.1:3306/day07property>
        <property name="user">rootproperty>
        <property name="password">1234property>

        
        <property name="checkoutTimeout">30000property>
        <property name="idleConnectionTestPeriod">30property>
        <property name="initialPoolSize">10property>
        <property name="maxIdleTime">30property>
        <property name="maxPoolSize">100property>
        <property name="minPoolSize">10property>
        <property name="maxStatements">200property>
    default-config> 


    
    <named-config name="itcast">
        <property name="driverClass">com.mysql.jdbc.Driverproperty>
        <property name="jdbcUrl">jdbc:mysql://127.0.0.1:3306/xxxxproperty>
        <property name="user">rootproperty>
        <property name="password">1234property>


        
        <property name="acquireIncrement">5property>
        <property name="initialPoolSize">20property>
        <property name="minPoolSize">10property>
        <property name="maxPoolSize">40property>
        <property name="maxStatements">20property>
        <property name="maxStatementsPerConnection">5property>
    named-config>
c3p0-config> 

你可能感兴趣的:(JAVA)