<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
<classpathentry kind="var" path="TOMCAT_LIBS_BASE/tomcat6-deps/dbcp/tomcat-dbcp.jar" sourcepath="/TOMCAT_LIBS_BASE/tomcat6-deps/dbcp/src/java"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/development/tomcat/trunk/trunk/modules/jdbc-pool/includes/h2/bin/h2-1.1.118.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
<delete file="${base.path}/file.zip"/>
</target>
- <target name="download">
+ <target name="download" unless="skip.download">
<mkdir dir="${base.path}"/>
<!--
<antcall target="downloadzip">
//set up the default state, unless we expect the interceptor to do it
if (poolProperties.getJdbcInterceptors()==null || poolProperties.getJdbcInterceptors().indexOf(ConnectionState.class.getName())<0) {
+ if (poolProperties.getDefaultTransactionIsolation()!=DataSourceFactory.UNKNOWN_TRANSACTIONISOLATION) connection.setTransactionIsolation(poolProperties.getDefaultTransactionIsolation());
if (poolProperties.getDefaultReadOnly()!=null) connection.setReadOnly(poolProperties.getDefaultReadOnly().booleanValue());
if (poolProperties.getDefaultAutoCommit()!=null) connection.setAutoCommit(poolProperties.getDefaultAutoCommit().booleanValue());
if (poolProperties.getDefaultCatalog()!=null) connection.setCatalog(poolProperties.getDefaultCatalog());
- if (poolProperties.getDefaultTransactionIsolation()!=DataSourceFactory.UNKNOWN_TRANSACTIONISOLATION) connection.setTransactionIsolation(poolProperties.getDefaultTransactionIsolation());
}
this.discarded = false;
this.lastConnected = System.currentTimeMillis();
public void reset(ConnectionPool parent, PooledConnection con) {
if (parent==null || con==null) return;
PoolConfiguration poolProperties = parent.getPoolProperties();
+ if (poolProperties.getDefaultTransactionIsolation()!=DataSourceFactory.UNKNOWN_TRANSACTIONISOLATION) {
+ try {
+ if (transactionIsolation==null || transactionIsolation.intValue()!=poolProperties.getDefaultTransactionIsolation()) {
+ con.getConnection().setTransactionIsolation(poolProperties.getDefaultTransactionIsolation());
+ transactionIsolation = Integer.valueOf(poolProperties.getDefaultTransactionIsolation());
+ }
+ }catch (SQLException x) {
+ transactionIsolation = null;
+ log.error("Unable to reset transaction isolation state to connection.",x);
+ }
+ }
if (poolProperties.getDefaultReadOnly()!=null) {
try {
if (readOnly==null || readOnly.booleanValue()!=poolProperties.getDefaultReadOnly().booleanValue()) {
log.error("Unable to reset default catalog state to connection.",x);
}
}
- if (poolProperties.getDefaultTransactionIsolation()!=DataSourceFactory.UNKNOWN_TRANSACTIONISOLATION) {
- try {
- if (transactionIsolation==null || transactionIsolation.intValue()!=poolProperties.getDefaultTransactionIsolation()) {
- con.getConnection().setTransactionIsolation(poolProperties.getDefaultTransactionIsolation());
- transactionIsolation = Integer.valueOf(poolProperties.getDefaultTransactionIsolation());
- }
- }catch (SQLException x) {
- transactionIsolation = null;
- log.error("Unable to reset transaction isolation state to connection.",x);
- }
- }
+
}
@Override