On Sat, Nov 3, 2012 at 3:04 PM, Stephan <[email protected]> wrote:
> I'd like to get all the ready jobs at once process them and then go back to
> waiting after each batch processing is done to start another batch
> processing.

Why do you want to do this?

You can do it if you really want to. Call reserve with a 0 timeout
in a loop until there are no jobs available, process them all, then
call reserve without a timeout to wait for the next job to arrive.

Here's some pseudocode:

while True:
    jobs = [reserve()]
    while True:
        j = reserve(timeout=0)
        if j is None:
            break
        jobs.append(j)
    process(jobs)

-- 
You received this message because you are subscribed to the Google Groups 
"beanstalk-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/beanstalk-talk?hl=en.

Reply via email to