I have a struts web application and have some actions which i want to run every night for instance, every night run the action that searches the database for users who have been marked as deleted and remove them from the database.
I was wondering what the best(most performant) way is to run these actions that need to run at certain times of the day, month, year, etc. So i guess what i am asking is what the best was is to run tasks that need to run every day, year, etc at a certain time in Java.
Thanks for any help given.
posted 8 years ago
There are many different ways to do this. The simplest would probably be a command line shell script/batch job on the server to call the servlet. However if you want something more robust, you might want to check out the quartz package for scheduling jobs