Q1) What if we are using cache to cache a lookup table data? How do you set a key when we have a lot of data, because there might be a lot of records/attributes in a lookup table Q2) If this cachable is used in memory cache, then everything gets stored in the server's storage, and it gets bloated along with all the objects/variables, etc..
Thanks for asking these questions Q1: If caching a lookup table with many records, you can either cache the entire table under a single key for static data or cache individual records using unique keys (like the primary key). Choose based on your access pattern and data size. Q2: Yes, in-memory caches can bloat server memory. To manage this, use eviction policies, set expiration times (TTL), or opt for distributed caches like Redis to offload storage from the application memory.
Awesome video ❤
Thanks
Q1) What if we are using cache to cache a lookup table data? How do you set a key when we have a lot of data, because there might be a lot of records/attributes in a lookup table
Q2) If this cachable is used in memory cache, then everything gets stored in the server's storage, and it gets bloated along with all the objects/variables, etc..
Thanks for asking these questions
Q1: If caching a lookup table with many records, you can either cache the entire table under a single key for static data or cache individual records using unique keys (like the primary key). Choose based on your access pattern and data size.
Q2: Yes, in-memory caches can bloat server memory. To manage this, use eviction policies, set expiration times (TTL), or opt for distributed caches like Redis to offload storage from the application memory.