Re: Run a cron job in cakephp

2011-11-04 Thread Eric Blanpied
My workers are just PHP. I've got one doing curl stuff to transfer big files, and another to drive ffmpeg for slow encodes. You can write your Gearman clients in pretty much anything, though. They've got a bunch of client libraries. The PHP one is pretty comprehensive, and I've experimented with py

Re: Run a cron job in cakephp

2011-11-04 Thread zuha
Cron is not only for particular times, its also for recurring events. It certainly does make sense if you simply set your task to check what time it is before executing. Then you just "try" to run it every minute (or every page load), and it will fire only at the appropriate time. This makes

Re: Run a cron job in cakephp

2011-11-04 Thread zuha
Oh that looks promising, if anything it should at least get us started. Thank you for that : https://github.com/MSeven/cakephp_queue/wiki -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and h

Re: Run a cron job in cakephp

2011-11-04 Thread Werner Petry Moraes
Hi, that cake method you call from within the worker, is it written as a shell? Or how do you do it? I'm not familiar with gearman, but I think I'm gonna need it soon. thanks atenciosamente, Werner Petry Moraes werne...@gmail.com On Fri, Nov 4, 2011 at 06:16, Eric Blanpied wrote: > I think t

Re: Run a cron job in cakephp

2011-11-04 Thread Eric Blanpied
I think the best way to do it is with a queue. After doing several websites in which cron jobs were used for various not-so-cron things (cron job to wake up periodically and check for needed tasks? why not just spawn the tasks?), I came to the conclusion that a job queue was a much smarter answer.

Re: Run a cron job in cakephp

2011-11-04 Thread flo.kl...@googlemail.com
What about using javascript. It would only work while the user is on the site, but it would be able to call a function (also ajax if you want to trigger a php method) very x seconds. -flosky Ryan Schmidt schrieb: On Nov 4, 2011, at 00:17, zuha wrote: > is there anyway to run a process sep

Re: Run a cron job in cakephp

2011-11-03 Thread Ryan Schmidt
On Nov 4, 2011, at 00:17, zuha wrote: > is there anyway to run a process separate from the page load. I would love > to run a pseudo cronjob on each page load if it could be done without > negatively effecting performance in a serious way. (I was thinking curl, and > ajax, but they didn't re

Re: Run a cron job in cakephp

2011-11-03 Thread Greg Skerman
I was reading recently about a deferred execution pluginwhich kind of did that I thought (i've not actually used it..) https://github.com/MSeven/cakephp_queue/wiki Queues a job, which gets picked up periodically by a worker and doesn't hold up the page load. Might be worth a look. On Fri,

Re: Run a cron job in cakephp

2011-11-03 Thread zuha
While we're on the topic though... is there anyway to run a process separate from the page load. I would love to run a pseudo cronjob on each page load if it could be done without negatively effecting performance in a serious way. (I was thinking curl, and ajax, but they didn't really seem to

Re: Run a cron job in cakephp

2011-11-03 Thread Ryan Schmidt
On Nov 3, 2011, at 23:29, abhimanyu bv wrote: > @euromark, > can you help me using crontab you posted in that link. This isn't a CakePHP question. You should be able to find many tutorials online about how to use cron. -- Our newest site for the community: CakePHP Video Tutorials http://tv

Re: Run a cron job in cakephp

2011-11-03 Thread abhimanyu bv
@euromark, can you help me using crontab you posted in that link. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this

Re: Run a cron job in cakephp

2011-11-03 Thread euromark
you can use crontab to do that http://book.cakephp.org/view/1110/Running-Shells-as-cronjobs and here is explained how you can set the time accordingly: http://neeocis.wordpress.com/2008/07/08/crontab-every-five-minutes/ On 4 Nov., 03:21, Thiago Belem wrote: > Running a cronjob is something you

Re: Run a cron job in cakephp

2011-11-03 Thread Thiago Belem
Running a cronjob is something you do on your operating system, give a look: http://en.wikipedia.org/wiki/Cron Use this to call your shell task and you're done. :) -- ***Thiago Belem* Desenvolvedor Rio de Janeiro - RJ - Brasil +55 (21) 8865.9250 thiagobelem.net cont...@thiagobelem.net *Skype / g

Run a cron job in cakephp

2011-11-03 Thread abhimanyu bv
I would like to write a cron job that has to run a PHP script at 6am, 11am,2pm,4pm on each day. Can you please help me with this? I wrote a shell task in shells and I want to run that task at the timings i said in the earlier statement. Thanks. -- Our newest site for the community: CakePHP Vide

RE: Run a cron Job

2009-09-28 Thread Dave Maharaj :: WidePixels.com
/vendors/shell I would use something like /mypath/to/cake/console/cake -app /mypath/app reports (mypath being changed obviously) Dave -Original Message- From: brian [mailto:bally.z...@gmail.com] Sent: September-28-09 2:15 PM To: cake-php@googlegroups.com Subject: Re: Run a cron Job On Mon, Sep

Re: Run a cron Job

2009-09-28 Thread brian
On Mon, Sep 28, 2009 at 12:24 PM, Dave Maharaj :: WidePixels.com wrote: > > Yeah I set up a reports.php like they did in the Cookbook but even when I > try to run it from the control panel I keep getting '/bin/sh: 15: command > not found' It looks like you're trying to feed the shell the example

RE: Run a cron Job

2009-09-28 Thread Dave Maharaj :: WidePixels.com
mileswjohn...@gmail.com] Sent: September-28-09 1:49 PM To: CakePHP Subject: Re: Run a cron Job Cron isn't run through PHP, I think thats what your trying to get at. You have to setup cron jobs through your hosts control panel, or at least figure out where you define your cron jobs. On Sep 28, 8:58 a

Re: Run a cron Job

2009-09-28 Thread Miles J
Cron isn't run through PHP, I think thats what your trying to get at. You have to setup cron jobs through your hosts control panel, or at least figure out where you define your cron jobs. On Sep 28, 8:58 am, brian wrote: > On Mon, Sep 28, 2009 at 10:02 AM, Dave Maharaj :: WidePixels.com > > wro

Re: Run a cron Job

2009-09-28 Thread brian
On Mon, Sep 28, 2009 at 10:02 AM, Dave Maharaj :: WidePixels.com wrote: > > Ok, thanks, > > I want the cron to run by its self at a specific time. SoI do not have to do > it myself daily. Can this be done in your approach? New to cron set up. > Yes, this is exactly what cron is for. You'd enter

RE: Run a cron Job

2009-09-28 Thread Dave Maharaj :: WidePixels.com
: September-28-09 9:33 AM To: CakePHP Subject: Re: Run a cron Job The cake shell is prefect for this. I do cron tasks by creating Cake shell tasks and from there I do a requestAction if I really need to call an action. This is what I tell cron: /ful/path/to/cake/console/cake -app /full/path/to/app

Re: Run a cron Job

2009-09-28 Thread Martin Westin
The cake shell is prefect for this. I do cron tasks by creating Cake shell tasks and from there I do a requestAction if I really need to call an action. This is what I tell cron: /ful/path/to/cake/console/cake -app /full/path/to/app shellname >>/dev/ null 2>&1 The last bit (dev/null and that) ma

Run a cron Job

2009-09-27 Thread Dave Maharaj :: WidePixels.com
Trying to set up an action to run at a specific time. Found a few sites saying replace require CORE_PATH.'cake'.DS.'bootstrap.php'; in index.php but no longer appears to be there. Any good places to look where to set this up? Thanks Dave --~--~-~--~~~---~--~--