public function run()
    {
        if ($job = $this->pop()) {
            list($route, $payload, $execution) = $job;
            $result = $this->runJob($route, $payload);
            if ($result === false) {
                if ($execution > 1) {
                    $this->push($route, $payload, 0, $execution - 1);
                } else {
                    $this->trigger(self::EVENT_FAIL, new Event(['route' => $route, 'payload' => $payload]));
                }
            }
            return $result !== false;
        }
    }
public function run()
    {
        if ($job = $this->pop()) {
            list($route, $payload, $execution) = $job;
            $result = $this->runJob($route, $payload);
            if ($result === false) {
                if ($execution > 1) {
                    $this->push($route, $payload, 0, $execution - 1);
                } else {
                    $this->trigger(self::EVENT_FAIL, new Event(['route' => $route, 'payload' => $payload]));
                }
            }
            return $result !== false;
        }
    }
public function run ( ) { if ( $ job = $ this -> pop ( ) ) { list ( $ route , $ payload , $ execution ) = $ job ; $ result = $ this -> runJob ( $ route , $ payload ) ; if ( $ result === false ) { if ( $ execution > 1 ) { $ this -> push ( $ route , $ payload , 0 , $ execution - 1 ) ; } else { $ this -> trigger ( self :: EVENT_FAIL , new Event ( [ 'route' => $ route , 'payload' => $ payload ] ) ) ; } } return $ result !== false ; } }
Run top of job in queue.
Run top of job in queue .