Sub-workflows in queue mode – are all depths executed by the same worker?

Hi everyone,

Today we made a pleasant/unpleasant discovery. We spent many hours trying to figure out how to balance queue mode and workers. We noticed that for some reason one worker was getting almost all the load, while the logs didn’t show other workers starting jobs at all.

Eventually, we realized that if a workflow has sub-workflows and they go several levels deep, the first execution picked up by a worker will continue being processed by that same worker until everything is finished — the main workflow and all sub-sub-sub workflows - at it took up to 1 minute.

This feels a bit strange, as we were convinced that sub-workflows should be executed by separate workers.

Our questions are:

  • Is our env configuration set up incorrectly?

  • Or is this actually how n8n works — that one job includes the full execution chain (with all sub-workflows) and gets processed entirely by the same worker?

Would love to hear your experiences. Thanks!

Hey, if you are using the Sub-workflow nodes to trigger sub-workflows, then this seems like the expected behavior of n8n at the moment.

If you adjust to trigger the sub-workflows via webhooks instead, they should count as separate executions and should be able to distribute across workers. Please give this pattern a try:

Let me know if you manage to test it successfully.

1 Like

That’s the tricky and interesting part with n8n: once we switch from HTTP/webhook triggers to sub-workflows, it feels more sustainable and stable — but there’s definitely a dark side to it :sweat_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.