redding/dat-worker-pool — pull request #6 by jcredding (2013-08-18 02:29:37+00:00)
Title: Modify the worker-queue interactions

This modifies the worker-queue interaction. Now, workers "waiting"
is internally handled when trying to pop work from the queue. The
queue sleeps the thread if there isn't any work available. This
addresses an issue of workers pulling work from the queue and
getting `nil` back. This occurred because of race conditions.
Multiple workers would be active trying to get work, causing some
to get `nil` back and try and run it as "work". This only seemed
to occur with 3+ workers active.

@kellyredding - This isn't ready for review yet.