hibiken / asynq

Simple, reliable, and efficient distributed task queue in Go
MIT License
9.49k stars 688 forks source link

How to add concurrency to a task ? #846

Closed sdfjklmin closed 6 months ago

sdfjklmin commented 6 months ago

How to add concurrency to a task ?

awanganddong commented 6 months ago

You can recreate a server and specify queues for each of the two servers. so that tasks go into the corresponding queue.

This way, one server sets one concurrency, and the other server can set multiple concurrencies

client.Enqueue(task1, asynq.Queue("notifications"))