Skip to content

Commit

Permalink
set lock expiry
Browse files Browse the repository at this point in the history
  • Loading branch information
limenet committed Dec 16, 2022
1 parent f168c9d commit 53ce5e5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/Jobs/AbstractIndexJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ public function uniqueId(): string

public function middleware(): array
{
return [new WithoutOverlapping($this->uniqueId())];
return [
(new WithoutOverlapping($this->uniqueId()))
->expireAfter(now()->addMinutes(30)),
];
}
}

0 comments on commit 53ce5e5

Please sign in to comment.