Oracle getConnection slow Oracle getConnection slow oracle oracle

Oracle getConnection slow


Was due to java using /dev/random instead of /dev/urandom to make a ssh connection with the database.... switching to /dev/urandom fixed this


2 questions.

First, after you get the first connection, what are you doing with it? Are you closing it correctly (INCLUDING all resources you opened with it, like Statement and ResultSet)?

Second, how many connections does your DB allow you for the credentials you logged in with?

The reason I ask these questions is that the time delays may be the amount of time it takes for the DB to clean up after you (because you may not have done it right) and free up a connection to give you. Much of this could just be timeouts before it forcefully releases resources.


Are you exceeding your max active connections in your connection pool and have to wait for your program to release old connections?