We are developing a Java web application using Spring, Hibernate and MySQL.
I want our application to automatically backup the MySQL database daily; is there any way to accomplish that with Java code?
|
This is easy to do.
It is worth while putting some backup file cycling into the script so that you keep, say, every backup from the last week and delete the rest. Also remember to backup to a physically different disk from the database itself so you have a backup if the disk dies. |
||||
|
You can user Quartz-scheduler to schedule the backup, take a look here on how to schedule an automatic Hibernate backup. |
|||
|