New function for the number of retrials / Daily reload of hooks
This commit is contained in:
@@ -1365,6 +1365,17 @@ class Worker
|
||||
return $new_retrial;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the number of retrials for the current worker task
|
||||
*
|
||||
* @return integer
|
||||
*/
|
||||
public static function getRetrial(): int
|
||||
{
|
||||
$queue = DI::app()->getQueue();
|
||||
return $queue['retrial'] ?? 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defers the current worker entry
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user