MCPcopy
hub / github.com/open-policy-agent/gatekeeper / RemovableCache

Interface RemovableCache

pkg/watch/manager.go:64–68  ·  view source on GitHub ↗

RemovableCache is a subset variant of the cache.Cache interface. It supports non-blocking calls to get informers, as well as the ability to remove an informer dynamically.

Source from the content-addressed store, hash-verified

62// It supports non-blocking calls to get informers, as well as the
63// ability to remove an informer dynamically.
64type RemovableCache interface {
65 GetInformer(_ context.Context, obj client.Object, opts ...cache.InformerGetOption) (cache.Informer, error)
66 List(ctx context.Context, list client.ObjectList, opts ...client.ListOption) error
67 RemoveInformer(_ context.Context, obj client.Object) error
68}
69
70func New(c RemovableCache) (*Manager, error) {
71 metrics, err := newStatsReporter()

Callers 10

doAddWatchMethod · 0.65
ListMethod · 0.65
verifyTStatusCountFunction · 0.65
verifyCStatusCountFunction · 0.65
ReconcileMethod · 0.65
deleteAllStatusMethod · 0.65
listObjectsMethod · 0.65
applyCRDFunction · 0.65
ReconcileMethod · 0.65
doRemoveWatchMethod · 0.65

Implementers 2

fakeRemovableCachepkg/watch/manager_test.go
funcCachepkg/watch/manager_test.go

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…