Re: CakePHP 2.0 Percent Complete

2012-01-06 Thread AD7six
On Jan 5, 10:18 pm, GB wrote: > Based on my research CakePHP does not handle well the scenario that > may require updating a user periodically on progress (e.g. sending 20 > (200, 2000) emails:  1 of 20, 2 of 20, etc or even updating a jQuery > progress bar). > > In my case it would be easy to s

Re: CakePHP 2.0 Percent Complete

2012-01-05 Thread Graham Weldon
I'm going to briefly discuss the approach, and leave implementation up to you. - Send all your emails to a queue * Include a job or batch number thats the same for everything in this batch - Have the queue process the information * Use a message queue, a worker, or some other asynchronous pro

Re: CakePHP 2.0 Percent Complete

2012-01-05 Thread GB
Thanks all. I've looked at the MSeven solution and other consoles but was looking something more interactive. Basically a user selects a job that processes N tasks. Right now the 'waiting' message sits there and the user is unaware of where in 1..N they are. I have not succeeded in showing each

Re: CakePHP 2.0 Percent Complete

2012-01-05 Thread Geoff Douglas
This is a limitation of the web in general isn't it? In the web development world, each request is a unique call to the server... so there is no such thing as "progress." You request something, and the server responds. Even in the case where you pass over the processing to a daemon of some kind

Re: CakePHP 2.0 Percent Complete

2012-01-05 Thread majna
you can use PHP output buffering and flush progress (if you can't use cosnole/queues): ob_implicit_flush(true); foreach(...) { echo 'updateMyProgress(' . $current . ',' . $total . ');'; // or jquery progress bar stuff flush(); } But it's a bit retarded and you can't stop this :) --

Re: CakePHP 2.0 Percent Complete

2012-01-05 Thread euromark
many of us would use sth like https://github.com/MSeven/cakephp_queue and not making the user/frontend depend on the result/progress On 5 Jan., 22:18, GB wrote: > Based on my research CakePHP does not handle well the scenario that > may require updating a user periodically on progress (e.g. sendi

CakePHP 2.0 Percent Complete

2012-01-05 Thread GB
Based on my research CakePHP does not handle well the scenario that may require updating a user periodically on progress (e.g. sending 20 (200, 2000) emails: 1 of 20, 2 of 20, etc or even updating a jQuery progress bar). In my case it would be easy to send the CakePHP View the 20 URL's so that a