MCPcopy
hub / github.com/kubernetes/client-go / cache

Struct cache

tools/cache/store.go:112–118  ·  view source on GitHub ↗

cache responsibilities are limited to: 1. Computing keys for objects via keyFunc 2. Invoking methods of a ThreadSafeStorage interface

Source from the content-addressed store, hash-verified

110// 1. Computing keys for objects via keyFunc
111// 2. Invoking methods of a ThreadSafeStorage interface
112type cache struct {
113 // cacheStorage bears the burden of thread safety for the cache
114 cacheStorage ThreadSafeStore
115 // keyFunc is used to make the key for objects stored in and retrieved from items, and
116 // should be deterministic.
117 keyFunc KeyFunc
118}
119
120var _ Store = &cache{}
121

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected