jeudi 1 octobre 2015

Calling a specific method on a certain time

I am currently working on a web application and I want to schedule a method that runs every day at 6 AM. Basically, if the clock ticks at 6 AM, this method will run. I have seen some answers on the Internet but none of these are scheduled at a fixed time of the day but rather timed after the app is ran.

I also have an alternative solution which is to check every minute if the time is 6 AM, and if so, I'll run the code. But is there other better answer than this?

Thank you!




Aucun commentaire:

Enregistrer un commentaire