Said in the document can specify queue, but how to configure multiple queue!
Laravel
Framework
CodePudding user response:
I have the same problem
CodePudding user response:
Hello, the problem solved?
CodePudding user response:
Each connection has a default queue attributes, when assigned task queue if you do not use similar onQueue method to specify queue name, will be assigned to the default queue queue, the original poster only use redis, is only a redis connection, using the same connection (redis) of different queue, no additional configuration, just at the time of dispatch tasks onQueue method is used to specify the queue name you want, pay special attention to is when your task processor PHP artisan queue: the work must be specified, queue attributes (i.e.,PHP artisan queue: work - the queue=you just define the queue name
), because the default PHP artisan queue: work only deals with the default queue (redis links the default queue queue name attribute configuration), you specify a custom queue name, it is not processing
CodePudding user response:
So once using multiple queue, will have to consider to open multiple queue processor (more connected by the same token)
PHP artisan queue: work - the queue queue name=1;
PHP artisan queue: work - the queue queue name=2;
PHP artisan queue: work - the queue=queue name 3;