<div dir="ltr">Hi,<div><br></div><div>I wanted to show my design for a priority based task queue and get some insight from experts.</div><div><br></div><div>The client create a queue named: "some_tasks_to_work_on2" and put his tasks there,</div>
<div>then it puts the following message in a queue named "batch_states":</div><div>[{batch="some_tasks_to_work_on2", priority=3}]</div><div>now each worker can take the status message and get tasks from the batch.</div>
<div>if a few batches are in the status message then the worker check the queue by the priority order.</div><div><br></div><div>a worker should also return the status message after reading it so other workers can also read it.</div>
<div>now this is needed because i want workers to be able to wake up any time and get the latest status.</div><div>In this approch I can add new batches on the fly and also change priorities.</div><div><br></div><div>Do you think there is a better way to do it?</div>
<div><br></div><div><br></div></div>