Should queue consumer workers be separate from fetch workers?
You can return a worker with
fetch
or queue
or both. If I have my api on fetch and then also have queue stuff is it better to create a sperate worker and use queue there or...
1. It doesn't matter as cloudflare can split fetch and queue automatically
2. It doesn't matter as loading the entire worker for both is no problem1 Reply
Hey,
There is no disadvantage to using both fetch and queue in the same Worker. All queue consumer requests will go to the queue handler, and all fetch requests will go to the fetch handler.
It comes down to personal preference and how you want to structure your code.