protected function getNextWorker()
    {
        if ($this->nextWorkerAlgorithm !== null) {
            return call_user_func($this->nextWorkerAlgorithm, $this);
        } else {
            return $this->workers[mt_rand(0, $this->workerCount - 1)];
        }
    }