Configure the proxool connection pool according to the normal steps, configure automatic monitoring in web. xml, and perform a simple test to ensure that the connection pool works properly. Configure proxool. xml as follows:
1. proxool. xml
<? Xml version = "1.0" encoding = "ISO-8859-1"?>
<! -- The proxool configuration can be embedded within your own application's.
Anything outside the "proxool" tag is ignored. -->
<Something-else-entirely>
<Proxool>
<Alias> MyPool </alias>
<Driver-url> jdbc: microsoft: sqlserver: // localhost: 1433; DatabaseName = test; SelectMethod = cursor </driver-url>
<Driver-class> com. microsoft. jdbc. sqlserver. SQLServerDriver </driver-class>
<Driver-properties>
<Property name = "user" value = "testuser"/>
<Property name = "password" value = "testpwd"/>
</Driver-properties>
<Maximum-connection-count> 80 </maximum-connection-count>
<Minimum-connection-count> 20 </minimum-connection-count>
<House-keeping-sleep-time> 180000 <Prototype-count> 5 </prototype-count>
<House-keeping-test-SQL> select CURRENT_DATE </Proxool>
</Something-else-entirely>
2. applicationContext. there are two ways to configure the proxool connection pool in xml: one is to use the proxool configured above. xml file, another way is directly in applicationContext. for configuration in xml, see method 1 first:
<Bean id = "TestSource" class = "org. springframework. jdbc. datasource. DriverManagerDataSource">
<Property name = "driverClassName">
<Value> org. logicalcobwebs. proxool. ProxoolDriver </value>
</Property>
<Proper</