Metrics to assess cache usage
357
Views
2
Comments
New
Service Center

Regarding O11 and its caching capabilities (cache in minutes property on aggregates and server actions) it would be useful to have some metrics that allows us to understand the cache misses/cache hits or even cache miss ratio so that we validate if the cache in minutes property is being used wisely.

The goal here is to catch the incorrect usage of cache in minutes, sometimes this feature is uses without doing the right assessment of data skewness and its usage. Sometimes the evolution and usage of the applications makes the business data to grow/change making the cache somehow less useful

Having a cache with 70% miss ratio means we are missing the cache 7 out of 10 times, meaning, we are wasting resources (in this particular case, cache should not be used)

Its hard to find which modules and core are using cache. Its hard to check the cache size. Providing this metric would allows development teams and CoE to have visibility on the cache usage and adapt



Totally agree.

I would add that the size of the cache would also be a valuable information to have. Developers can easily cache hundreds of records by mistake. It would be nice to have this visibility and maybe even a warning.

Agreed!!  I have avoided using the OutSystems cache in minutes feature for many use cases. The main concern is that I may cause memory constraints by caching too much data.  

To help assess proper usage, I would like to know:

  1. The total size of cached items vs. memory available for cache
  2. Which apps, modules, and actions have data cached, any how many unique entries are cached (ex. One single Server Action may have 100 entries, due to many permutations of input parameters)
  3. How often the cached method is being accessed
  4. Time spent populating cache (Compare time savings of fetching from cache vs. fetching from db)