I have a Java (Swing) desktop connected to a godaddy MySQL database (online database). Till the time database was offline, this was not at all the problem, but now I get this exception when I try to access some menu which involves a database access. Also, I create a static connection object when my application start, and never close it when the application is running.
This is the description of Exception, please help if you can.
Thanks :)
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link fai lure
Last packet sent to the server was 47 ms ago.
SOME MORE STACK TRACE AND THEN THE CHAINED CAUSE
Caused by: java.io.EOFException: Can not read response from server. Expected to
read 4 bytes, read 0 bytes before connection was unexpectedly lost.