Skip to content

Commit 0c51961

Browse files
committed
rename queue checker name, and add metadata
1 parent 1b0692d commit 0c51961

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/Checks/QueueHealthCheck.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public function failIfJobTakesLongerThan($seconds)
4848

4949
public static function make($queue = 'default')
5050
{
51-
return (new static('queue-check.' . $queue))->queue($queue);
51+
return (new static($queue . '_queue'))->queue($queue);
5252
}
5353

5454
public function queue($queue)
@@ -100,6 +100,11 @@ public function run()
100100
} elseif ($lastJobDuration >= $this->warnAt) {
101101
$result = Result::warn("{$this->queue} wait time is getting longer. (> {$duration})");
102102
}
103+
104+
$result->meta([
105+
'queue' => $this->queue,
106+
'waitTime' => $duration,
107+
]);
103108
}
104109

105110
$dispatchAgain = $shouldDispatchNewJob && (

0 commit comments

Comments
 (0)