Good morning to everyone, I'm a new user and my English isn't the best around :-)
I'm using a web application and, sometimes, I have MySql connection problems. Using the testConnectionOnCheckout and preferredTestQuery options in the hibernate configuration file I resolved the problem and my application is ok now.
But, for better performances, I'd like to obtain the same effects of this option only when a particular event occurs in my application. So, for example, I'd like to obtain:
try{ ........... } catch(Exception e){ java code to obtain the same effect of testConnectionOnCheckout option with "Select 1" query }
Which java code I have to use? Best wishes, Emilio
|