MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / getCacheUtilization

Function getCacheUtilization

db/channel_cache_test.go:108–114  ·  view source on GitHub ↗
(stats *base.CacheStats)

Source from the content-addressed store, hash-verified

106}
107
108func getCacheUtilization(stats *base.CacheStats) (active, tombstones, removals int) {
109 active = int(stats.ChannelCacheRevsActive.Value())
110 tombstones = int(stats.ChannelCacheRevsTombstone.Value())
111 removals = int(stats.ChannelCacheRevsRemoval.Value())
112
113 return active, tombstones, removals
114}
115
116// Test Cases
117// - simple compact

Callers 3

TestChannelCacheStatsFunction · 0.85

Calls 1

ValueMethod · 0.45

Tested by

no test coverage detected