I use JDBC for connect to Oracle database. Application is running very long time. So I need if connection was not closed by server, not happened network disconnect etc.
Should I run small query or exists another way? Use isValid I cannot because this is not supported by jdbc driver.
I use JDBC for connect to Oracle database. Application is running very long time.
Share
Running a simple query, something like
is the most foolproof approach. That’s what most Java EE app servers do to verify that a connection from their connection pool is still active.