diff --git a/resources/views/docs/desktop/1/digging-deeper/queues.md b/resources/views/docs/desktop/1/digging-deeper/queues.md index 7ec8bde8..77d9e5ca 100644 --- a/resources/views/docs/desktop/1/digging-deeper/queues.md +++ b/resources/views/docs/desktop/1/digging-deeper/queues.md @@ -31,6 +31,7 @@ Once you publish the NativePHP config file using `php artisan vendor:publish`, y 'queues' => ['high'], 'memory_limit' => 1024, 'timeout' => 600, + 'sleep' => 3, ], 'four' => [ 'queues' => ['high'], @@ -52,8 +53,11 @@ If you do not provide values for any of these settings, the following sensible d 'queues' => ['default'], 'memory_limit' => 128, 'timeout' => 60, +'sleep' => 3, ``` +The `sleep` parameter defines the number of seconds the worker will wait (sleep) when there are no new jobs available. A lower value means the worker polls for new jobs more frequently, which might be more responsive but uses more CPU. A higher value reduces CPU usage but may introduce a slight delay in processing newly added jobs. + ### Managing workers The handy `QueueWorker::up()` and `QueueWorker::down()` methods available on `Facades\QueueWorker` can be used to start