<?php
namespace App\Jobs;
use App\Models\Port;
use GuzzleHttp\Client;
use Illuminate\Bus\Queueable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
class UpdateWeatherJob implements ShouldQueue
{
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
/**
* @var Port
*/
public $port;
/**
* @var String
*/
public $url;
/**
* UpdateWeatherJob constructor.
* @param Port $port
* @param String $url
*/
public function __construct(Port $port, String $url)
{
$this->port = $port;
$this->url = $url;
}
/**
* Execute the job.
*
* @return void
*/
public function handle()
{
sleep(5);
}
}
Nothing happens in Horizon? What could be wrong here?
Thanks for helping. I did had indeed QUEUE_CONNECTION I changed that but still not working. It's the first time I set this up in Forge. I did restart the daemon!