Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/Queue/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ public static function setResource(string $name, callable $callback, array $inje
public function shutdown(): Hook
{
$hook = new Hook();
$hook->groups(['*']);
$this->shutdownHooks[] = $hook;
return $hook;
}
Expand Down Expand Up @@ -174,6 +175,7 @@ public function stop(): self
public function init(): Hook
{
$hook = new Hook();
$hook->groups(['*']);
$this->initHooks[] = $hook;
return $hook;
}
Expand Down Expand Up @@ -298,6 +300,8 @@ public function start(): self
*/
$this->adapter->connection->decrement("{$this->adapter->namespace}.stats.{$this->adapter->queue}.processing");
}

$this->resources = [];
}
});

Expand All @@ -318,6 +322,7 @@ public function start(): self
public function workerStart(): Hook
{
$hook = new Hook();
$hook->groups(['*']);
$this->workerStartHook = $hook;
return $hook;
}
Expand Down Expand Up @@ -413,6 +418,7 @@ protected function validate(string $key, array $param, mixed $value): void
public function error(): Hook
{
$hook = new Hook();
$hook->groups(['*']);
$this->errorHooks[] = $hook;
return $hook;
}
Expand Down