Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Asynchronous job queue?
  • Hello,

    I'm trying to figure out the best angle on a job queue setup for my project, I have been googling for a couple of days now and don't feel that I'm much closer. The topic seems far too common for not being able to find a quicker answer making me wonder if I'm missing something obvious.

    I want to place jobs in a queue that are then run asynchronously by the server outside of the clientside request. This is the closest I got:

    I also found this but not sure if this is talking about the same kind of queue:

    Finally, I'm wondering if the answer is just to place items in a table and then have a cron/oil job clear them off every minute?

    For bonus points, can someone explain why I need Beanstalkd at all? What does it actually do? I would still need to run a cron job to make sure that the service itself stays running?!

    Very rambling, not very coherent, I'm well and truly lost, sorry.
    /Andy
  • HarroHarro
    Accepted Answer
    The Queue in the 2.0 Event package is an event queue, not a job queue.

    So far I haven't seen proper job queue implementations. Either they are very simple (like the one you found) or they are the type we use in our applications, which run on ZeroMQ or RabbitMQ, and are more geared towards large environments.

    This might be an interesting read: http://kamisama.me/2012/10/09/background-jobs-with-php-and-resque-part-1-introduction/

    I've been planning to look into it in more detail, but haven't gotten around to it.
  • Fine, I will roll my own then! 

    And great link, thanks!

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion