I'll describe my case:
I have an aws lambda that will expose an API interface that will return json data (by topic) which is cached. This lambda will also offer private endpoints to recalculate the public data, then clear cache (by topic) and return data from new.
On event based system these private endpoints will be invoked. So no control over them and recalculate means computation time.
So the idea is to implement a debounce/buffer. In order not to fire immediately on every request the clear cache/computaiton, but to store the request on a buffer then, on a certain time window, maybe with a scheduled lambda, check the buffer and fire an optimized cache bust.
What can be the right driver?
(light & easy to implement, since it would be just to store a bunch of lines that might be wiped out every five minutes, and store very simple data like datetimeRequest+topic ) in order to store these latest request and then on a certain frequency get this buffer and invoke uniquely (by topic) the cache buster?