File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
src/main/java/io/confluent/connect/jdbc/util Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -56,12 +56,13 @@ public synchronized Connection getConnection() {
5656 log .info ("The database connection is invalid. Reconnecting..." );
5757 close ();
5858 newConnection ();
59+ } else {
60+ log .debug ("Using existing database connection." );
5961 }
6062 } catch (SQLException sqle ) {
6163 log .debug ("Could not establish connection with database." , sqle );
6264 throw new ConnectException (sqle );
6365 }
64- log .debug ("Database connection established." );
6566 return connection ;
6667 }
6768
@@ -83,6 +84,7 @@ private void newConnection() throws SQLException {
8384 log .debug ("Attempting to open connection #{} to {}" , count , provider );
8485 connection = provider .getConnection ();
8586 onConnect (connection );
87+ log .info ("Database connection established." );
8688 return ;
8789 } catch (SQLException sqle ) {
8890 attempts ++;
You can’t perform that action at this time.
0 commit comments