docspell icon indicating copy to clipboard operation
docspell copied to clipboard

Jobs waiting in the queue

Open nnovaes opened this issue 3 years ago • 2 comments

Whenever I start a job it sits for a long time in the queue before it runs. Is there any place I can configure for jobs to start immediately, or, if there's some sort of scheduler, for me to decrease the time it takes to poll the queue for a new job?

Even with a single job scheduled this happens. Looking on the documentation it says this should be normal, but I only have one collective so no need for multiple executors.

"Since job executors are shared among all collectives, it may happen that a job is some time waiting until it is picked up by a job executor. You can always start more job executors to help out."

nnovaes avatar Aug 10 '22 13:08 nnovaes

Hi @nnovaes ,

this is probably due to a connectivity issue between the restserver and joex component. How are you running docspell, via docker? Did you configure base-url or internal-url? The joex component is triggered when a new job is put into the queue, but it also wakes up itself periodically (you can configure it, see this at scheduler.wakeup-period). It is triggered by a http call, if this is failing then only the wakeup-period is there as a fallback.

Even with one collective, it might be beneficial to have multiple executors if you upload many files. The note you cited is for the case when there are more collectives; then you could see jobs in waiting state, because the joex is busy with a job from a different collective. But with only one collective you should see a job running immediately.

eikek avatar Aug 11 '22 09:08 eikek

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. This only applies to 'question' issues. Always feel free to reopen or create new issues. Thank you!

stale[bot] avatar Sep 16 '22 00:09 stale[bot]