public function getWorker($engine, $logger)
    {
        $worker = $this->params['worker'];
        $WorkerClass = "josegonzalez\\Queuesadilla\\Worker\\" . $worker . "Worker";

        return new $WorkerClass($engine, $logger, [
            'queue' => $engine->config('queue'),
            'maxRuntime' => $engine->config('maxRuntime'),
            'maxIterations' => $engine->config('maxIterations')
        ]);
    }
public function getWorker($engine, $logger)
    {
        $worker = $this->params['worker'];
        $WorkerClass = "josegonzalez\\Queuesadilla\\Worker\\" . $worker . "Worker";

        return new $WorkerClass($engine, $logger, [
            'queue' => $engine->config('queue'),
            'maxRuntime' => $engine->config('maxRuntime'),
            'maxIterations' => $engine->config('maxIterations')
        ]);
    }
public function getWorker ( $ engine , $ logger ) { $ worker = $ this -> params [ 'worker' ] ; $ WorkerClass = "josegonzalez\\Queuesadilla\\Worker\\" . $ worker . "Worker" ; return new $ WorkerClass ( $ engine , $ logger , [ 'queue' => $ engine -> config ( 'queue' ) , 'maxRuntime' => $ engine -> config ( 'maxRuntime' ) , 'maxIterations' => $ engine -> config ( 'maxIterations' ) ] ) ; }
Retrieves a queue worker

@param \josegonzalez\Queuesadilla\Engine\Base $engine engine to run
@param \Psr\Log\LoggerInterface $logger logger
@return \josegonzalez\Queuesadilla\Worker\Base
Retrieves a queue worker