Skip to content

Get Cache Stats

GET
/api/system/cache/stats

Get comprehensive cache statistics (cache module removed).

Successful Response

ComprehensiveCacheStatsResponse

Response for comprehensive cache statistics.

Provides detailed statistics for global cache and all service-specific caches including hit rates, miss rates, eviction counts, efficiency scores, and performance metrics. Essential for cache tuning and optimization.

Fields:

  • global_cache: Global cache statistics dictionary (required, JsonDict)
  • service_caches: Service-specific cache stats dictionary (required, JsonDict)
  • totals: Aggregated totals dictionary (required, JsonDict)

Usage: GET /api/system/cache/stats returns this response model with comprehensive cache statistics.

JSON Example:

{
  "globalCache": {
    "hits": 1543,
    "misses": 287,
    "hitRate": 84.31,
    "currentSize": 156
  },
  "serviceCaches": {
    "etherforce": {"hits": 234, "misses": 12},
    "lorekeeper": {"hits": 89, "misses": 45}
  },
  "totals": {
    "totalHits": 1866,
    "totalMisses": 344,
    "totalEntries": 1423
  }
}
object
globalCache
required
Globalcache

Global cache statistics

object
key
additional properties
Any of:
string
serviceCaches
required
Servicecaches

Service-specific cache stats

object
key
additional properties
Any of:
string
totals
required
Totals

Aggregated totals

object
key
additional properties
Any of:
string