Two possible approaches, if your responding to user requests to invoke
report generation I've used 'exec' with 'nice. The request is made by the
user, which then invokes the shell task, and then redirects to another page.
This page is automatically reloaded, on each time it monitors the status of
the shell task. I handled this by checking a "running_tasks" table, which
has some data about the invoked task, and a potential return code.

<?php exec("nice /path/to/cake shell"); ?>

If you're talking about non-user invoked tasks, investigate cron tasks.

Hope this helps,
Richard


On Mon, Jul 13, 2009 at 7:46 AM, gianpaulo <gcbasa...@gmail.com> wrote:

>
> Is it possible for CakePHP to execute a shell task on background for
> i.e running long reports. I would also want to report the current
> status back to the user either via updating a table during the report
> generation. Has anyone in  this group done something like this?
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to