Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager interface {
// Get configmap by configmap namespace and name.
GetConfigMap(namespace, name string) (*v1.ConfigMap, error)
// RegisterPod registers all configmaps from a given pod.
RegisterPod(pod *v1.Pod)
// UnregisterPod unregisters configmaps from a given pod that are not
// used by any other registered pod.
UnregisterPod(pod *v1.Pod)
}
func NewCachingConfigMapManager ¶
func NewCachingConfigMapManager(kubeClient clientset.Interface, getTTL manager.GetObjectTTLFunc) Manager
NewCachingConfigMapManager creates a manager that keeps a cache of all configmaps necessary for registered pods. It implement the following logic:
- whenever a pod is create or updated, the cached versions of all configmaps are invalidated
- every GetObject() call tries to fetch the value from local cache; if it is not there, invalidated or too old, we fetch it from apiserver and refresh the value in cache; otherwise it is just fetched from cache
func NewFakeManager ¶
func NewFakeManager() Manager
func NewSimpleConfigMapManager ¶
func NewSimpleConfigMapManager(kubeClient clientset.Interface) Manager
Click to show internal directories.
Click to hide internal directories.