From 0b70bf59b8dbbff45e038a45fe81cfddd441c422 Mon Sep 17 00:00:00 2001 From: brettwooldridge Date: Thu, 5 Dec 2013 23:40:59 +0900 Subject: [PATCH] Document new properties. --- README.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 7d388c28..832ba0f2 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ the agent jar. See below for details. com.zaxxer HikariCP - 1.1.8 + 1.1.9 compile @@ -41,7 +41,7 @@ the agent jar. See below for details. com.zaxxer HikariCP-agent - 1.1.8 + 1.1.9 compile @@ -103,6 +103,11 @@ This property controls the number of milliseconds to delay between attempts to a connection to the database. If ``acquireRetries`` is 0, this property has no effect. *Default: 750* +``connectionInitSql``
+This property sets a SQL statement that will be executed after every new connection creation +before adding it to the pool. If this SQL is not valid or throws an exception, it will be +treated as a connection failure and the standard retry logic will be followed. *Default: none* + ``connectionTestQuery``
This is for "legacy" databases that do not support the JDBC4 Connection.isValid() API. This is the query that will be executed just before a connection is given to you from the pool to @@ -184,6 +189,9 @@ method, like so: config.addDataSourceProperty("user", "SA"); config.addDataSourceProperty("password", ""); +See the [Initialization](#initialization) section below for further examples. + + ##### ***Missing Knobs*** ##### HikariCP has plenty of "knobs" to turn as you can see above, but comparatively less than some other pools.