I have a queue contains messages of different counts & I have script to read the queue and process the messages. My problem is: some of the queue has very larger number of messages & it exceeding than an usual. So, to improve the processing I would like to do process the queues which are all having the greater counts. If the queues are having the linear differences(eg: 1000, 1200, 1300, 1800, 1900) I want to process complete queue. If suppose the counts being like (1000, 1200, 1300, 1800, 1900, 4000, 4500, 4900, 5200) – here 4000+ are very larger queues So I want to take only these queues.
I hope some math calculations Standard deviation etc. will help but I have no idea how to approach it.
I would start like that: