A Redis-based multi-period rolling counter