MCPcopy Create free account
hub / github.com/GoMudEngine/GoMud / GetMemoryUsage

Function GetMemoryUsage

internal/templates/memory.go:5–12  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3import "github.com/GoMudEngine/GoMud/internal/util"
4
5func GetMemoryUsage() map[string]util.MemoryResult {
6 ret := map[string]util.MemoryResult{}
7
8 ret["templateCache"] = util.MemoryResult{Memory: util.MemoryUsage(templateCache), Count: len(templateCache)}
9 ret["templateConfigCache"] = util.MemoryResult{Memory: util.MemoryUsage(templateConfigCache), Count: len(templateConfigCache)}
10
11 return ret
12}
13
14func init() {
15 util.AddMemoryReporter(`Templates`, GetMemoryUsage)

Callers

nothing calls this directly

Calls 1

MemoryUsageFunction · 0.92

Tested by

no test coverage detected