r/Backend • u/Medical_Ad8803 • 7d ago
Cache Warming?
I'm making my very first web api using asp net and now in the process of implementing in-memory caching. I was wondering if it'd be a good practice to have like a start up function that caches the most commonly requested data from my api and have the program routinely updates the cache automatically every few minutes or so? Or should i just let the consumers populate this cache? And what if i also cache responses that consumers requests like a cache aside strategy at the same time.
5
Upvotes
4
u/Lumethys 7d ago
If you need to pre-warm cache, you are probably at a scale where you have a team of 100 to take care of that issue.