php-resque icon indicating copy to clipboard operation
php-resque copied to clipboard

Still job not found

Open ujwaldhakal opened this issue 8 years ago • 4 comments

\Resque::setBackend('redis:6379'); \Resque::enqueue('convert','App\\Job',['foobar' => 'bar']); this is how i setup my job

`namespace App;
use App\Service\Log;
class Job
{
    public function perform()
    {
        // .. Run job
        $a = new Log();
        $a->info('yellow',['done']);
        dd('ad');
    }

}`

My job file

"autoload": { "psr-4": { "App\\": "app" }, "files": [ "app/Job.php",

my composer

Job{convert} | ID: 9fae4414fd91f0d01598298ba87e3211 | App\Job | [{"foobar":"bar"}]) failed: Could not find job class App\Job. Issue i got

ujwaldhakal avatar Feb 25 '18 17:02 ujwaldhakal

How are you starting your worker(s)? And which version of PHP-Resque are you using?

danhunsaker avatar Feb 25 '18 18:02 danhunsaker

VVERBOSE=1 QUEUE=* php vendor/chrisboulton/php-resque/resque.php version 1.2

ujwaldhakal avatar Feb 25 '18 18:02 ujwaldhakal

Upgrade to master, and change vendor/chrisboulton/php-resque/resque.php to vendor/bin/resque, then try again.

danhunsaker avatar Feb 25 '18 19:02 danhunsaker

Thank you worked like a charms. Seems like this package hasnt been updated since 2nd mass extinction.

"require": { "chrisboulton/php-resque": "dev-master", }, final updated composer json.

ujwaldhakal avatar Feb 26 '18 08:02 ujwaldhakal