Efficient way to compute number of hits to a server within the last minute, in real time

Viewed 4647

Say you have a server that constantly gets HTTP requests. Your boss needs some stats, and asks you to compute the number of hits within the last minute at any given time.

What algorithm and data-structure would you use to achieve this?

2 Answers
Related