This commit is contained in:
Andras Bacsai
2023-05-23 09:53:24 +02:00
parent c023fdae8b
commit ee515ff940
16 changed files with 69 additions and 32 deletions

View File

@@ -5,13 +5,14 @@ namespace App\Jobs;
use App\Models\Application;
use App\Models\Server;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeUnique;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Queue\SerializesModels;
use Illuminate\Support\Facades\Log;
class ContainerStatusJob implements ShouldQueue
class ContainerStatusJob implements ShouldQueue, ShouldBeUnique
{
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
@@ -19,6 +20,10 @@ class ContainerStatusJob implements ShouldQueue
public string|null $container_id = null,
) {
}
public function uniqueId(): string
{
return $this->container_id;
}
public function handle(): void
{
try {