5 messages in com.googlegroups.pylons-discussRe: Best place to put periodic tasks?
FromSent OnAttachments
paul27 Feb 2008 16:02 
Ross Vandegrift27 Feb 2008 20:08 
Mike Orr27 Feb 2008 20:24 
paul27 Feb 2008 22:31 
paul27 Feb 2008 22:32 
Subject:Re: Best place to put periodic tasks?
From:Ross Vandegrift (ross@public.gmane.org)
Date:02/27/2008 08:08:53 PM
List:com.googlegroups.pylons-discuss

On Feb 27, 7:02 pm, paul <pah.@public.gmane.org> wrote:

2, This process that I would like to run (db query basically) takes some time to run so id like to sort of 'fork' it if possible so that it doesnt hold up the rest of my app from serving requests. I just use it to sync up my local object cache and so i dont need to wait for its completion

I have a similar thing I'm looking to do and recently learned how to extend paster to add commands. This works really well - you command can load up the model and use all of your model code as is, it's divorced from request handling, and it runs in its own process.

Check out
http://wiki.pylonshq.com/display/pylonscookbook/Cron+jobs+and+command-line+utilities