pmem / CacheLib

Pluggable in-process caching engine to build and scale high performance services
https://www.cachelib.org
Apache License 2.0
5 stars 13 forks source link

Added per pool per class used size metrics #61

Closed guptask closed 2 years ago

guptask commented 2 years ago

This change is Reviewable

guptask commented 2 years ago

This per pool size statistics reports the current size of each memory pool. Existing implementation does not report this statistic, specifically:

  1. fragmentation size statistic tracks fragmentation loss due to bad allocation - it is used to trigger increase in alloc size if configured to do so.
  2. getPool statistics reports the total capacity for each pool - it is useful to track whether a particular pool capacity grew or shrunk.
  3. allocation statistics does not track allocation per slab - so it cannot be used to calculate the size of a particular memory pool