Rails time triggered actions

Is there a way to make some method to act on a specific time?

Right now, i managed to bypass this problem by attaching this method to
the login factor of the site (everytime an admin log in the site, also
this method is called) , but there is a more direct and time related
way?

Enzo R. wrote:

Is there a way to make some method to act on a specific time?

Right now, i managed to bypass this problem by attaching this method to
the login factor of the site (everytime an admin log in the site, also
this method is called) , but there is a more direct and time related
way?

If you’re on a *NIX system your should use cron to run a standalone
program. Start it with script/runner to gain access to all the models
defined by your Rails application. If you just need to call a URL, use
cron to run a wget to that URL.

Windows has it’s own scheduled tasks systems so you should be able to
solve your problems there as well.

Take a look at Rufus Scheduler (http://rufus.rubyforge.org/rufus-
scheduler/) is working great for me, and is not plataform dependent.

Regards.

Franco C…

On Jul 15, 5:29 am, Enzo R. [email protected]

thanks a lot :wink:

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs