diff --git a/build.gradle b/build.gradle index 2f7ca2875b254ee22c21b18a2ab3645ed664b687..1599bb12f98ab8a3488634f86760144ec4b07a57 100644 --- a/build.gradle +++ b/build.gradle @@ -292,6 +292,21 @@ task javadocJar(type: Jar, dependsOn: javadoc) { classifier 'javadoc' } +task processResourcesTest << { + if (!isRelease) { + // we add a config-test.xml for SNAPSHOT releases (so that the cfg.tablePrefix is defined) + // otherwise testing and stable version would collide on testsystem + // and testing in jenkins would search for geoserver/postgis on jenkins-server + // (since localhost is default value in config-files -> needed for development) + copy { + from('src/test/resources') { + include '*-test.xml' + } + into "${project.buildDir}/resources/main" + } + } +} + task sourcesJar(type: Jar, dependsOn: classes) { description = 'Builds a jar file including sources' from sourceSets.main.allSource @@ -357,5 +372,6 @@ task release tasks.cleanAfterDaily.dependsOn cleanNodeModules tasks.daily.finalizedBy cleanAfterDaily tasks.daily.mustRunAfter clean +tasks.processResources.finalizedBy processResourcesTest tasks.test.finalizedBy cleanTestResults tasks.vagrantUp.dependsOn vagrantPrepare diff --git a/src/main/resources/config.xml b/src/main/resources/config.xml index 76c113fafc693536a85b2090cabf0a21cb12e95e..2c636220c61c085067fad3f08cb877720b2bb582 100644 --- a/src/main/resources/config.xml +++ b/src/main/resources/config.xml @@ -3,7 +3,7 @@ <properties> <!-- Global database settings --> <entry key="db.maxConnections">50</entry> - <entry key="db.pooling">false</entry> + <entry key="db.pooling">true</entry> <!-- Postgres database --> <entry key="org.postgresql.servername">localhost</entry>