changeset 8484:8c615d738e84

maxWait should be set independendly of validationQuery.
author Tom Gottfried <tom@intevation.de>
date Fri, 28 Nov 2014 10:21:40 +0100
parents 2db7a949ff8b
children 026f4c684ee5
files backend/src/main/java/org/dive4elements/river/backend/utils/DBCPConnectionProvider.java
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/backend/src/main/java/org/dive4elements/river/backend/utils/DBCPConnectionProvider.java	Thu Nov 27 20:25:31 2014 +0100
+++ b/backend/src/main/java/org/dive4elements/river/backend/utils/DBCPConnectionProvider.java	Fri Nov 28 10:21:40 2014 +0100
@@ -215,8 +215,10 @@
             String validationQuery = props.getProperty("validationQuery");
             if (validationQuery != null) {
                 ds.setValidationQuery(validationQuery);
-                ds.setMaxWait(1000); //TODO: make it configurable
             }
+
+            ds.setMaxWait(1000); //TODO: make it configurable
+
             // The BasicDataSource has lazy initialization
             // borrowing a connection will start the DataSource
             // and make sure it is configured correctly.

http://dive4elements.wald.intevation.org