Skip to content

Commit b9cbac1

Browse files
authored
- added an implementation of the Isolatable interface (#48000)
- added isolatableId
1 parent 99d004a commit b9cbac1

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

src/Illuminate/Queue/Console/RetryBatchCommand.php

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@
44

55
use Illuminate\Bus\BatchRepository;
66
use Illuminate\Console\Command;
7+
use Illuminate\Contracts\Console\Isolatable;
78
use Symfony\Component\Console\Attribute\AsCommand;
89

910
#[AsCommand(name: 'queue:retry-batch')]
10-
class RetryBatchCommand extends Command
11+
class RetryBatchCommand extends Command implements Isolatable
1112
{
1213
/**
1314
* The console command signature.
@@ -50,4 +51,14 @@ public function handle()
5051

5152
$this->newLine();
5253
}
54+
55+
/**
56+
* Get the custom mutex name for an isolated command.
57+
*
58+
* @return string
59+
*/
60+
public function isolatableId()
61+
{
62+
return $this->argument('id');
63+
}
5364
}

0 commit comments

Comments
 (0)