Little’s law
I’m currently involved in a large redevelopment project in my day job, a question has come up. How long will a message spend in our messaging layer (but it could be applied to the system as a whole)? This is an excellent question. We can determine this using Little’s law, (Thanks Eamonn).
Little’s law states that
The long-term average number of customers in a stable system L (known as the Offered load), is equal to the long-term average arrival rate, λ, multiplied by the long-term average time a customer spends in the system, W, or: L = λW
If we know that at our peak we will be recieving 200 messages a second and the backlog in the messaging layer is 20. Then we know that at peak a message will spend 100 milliseconds in the messaging layer. The trick here is to find the correct average figures.

