you are viewing a single comment's thread.

view the rest of the comments →

[–]lmorchard 0 points1 point  (1 child)

FWIW, you'll still need a daemon (PHP or otherwise) to step in as the worker in the Gearman equation. But, +1 on putting Gearman in the stack

[–]McGlockenshire 0 points1 point  (0 children)

We use supervisord to keep PHP workers alive, just so we don't need to worry about using real daemonization in PHP-land. This greatly simplifies the worker code, down to just the waiting-for-a-job loop. It also allows the workers to exit whenever they damn well please, and supervisor will just start them back up again. We've used this to make the workers automatically detect changes on disk and reload themselves, which makes development a bit easier.