MCPcopy
hub / github.com/openfaas/faas / FunctionCache

Struct FunctionCache

gateway/scaling/function_cache.go:20–24  ·  view source on GitHub ↗

FunctionCache provides a cache of Function replica counts

Source from the content-addressed store, hash-verified

18
19// FunctionCache provides a cache of Function replica counts
20type FunctionCache struct {
21 Cache map[string]*FunctionMeta
22 Expiry time.Duration
23 Sync sync.RWMutex
24}
25
26// NewFunctionCache creates a function cache to query function metadata
27func NewFunctionCache(cacheExpiry time.Duration) FunctionCacher {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected