[Question] Can worker avoid pick tasks for which does not have handler?
Hello,
I would like to check if it is expected behavior or if there is a way to change it.
I noticed if I connect a worker/consumer to the default queue that does not have implemented a handler for a certain pattern/task type, it still tries to consume the task and then puts back in queue incrementing the retry count and eventually exhaust all the retries.
Is expected that all workers connected to asynq on certain Redis instance, should be able to handle all types of tasks?
There might be some cases where some workers might interested in some kind of tasks and other in different ones. What should be the pattern to implement such use case? Different Redis instance? Different DB? Different queue names?
Could you try using ServerMux and see if the retry count is decremented.
I believe I'm already using the ServerMux:(https://gitlab.com/lealoureiro/jax-eda-go/-/blob/main/webhookworker/webhookworker.go?ref_type=heads Line 99.
The error: https://ibb.co/J5RzTLL
Because of the way that Redis works, asynq always needs to pick the task/object from redis and then put back correct?
Before I run that code to investigate further, could you debug with the inspector/CLI? This kind of issue usually comes about because of incorrect use of the library (based on the previous issues reporting something similar).
Post the results of queue info and servers.
Same issue:

Please let me know if you need more info
Same issue:
![]()
Please let me know if you need more info
did you find the solution?
I catch this issue in case of running two asynq server instances with the same settings, but different handlers. And didn't know how to resolve this situation.