MCPcopy
hub / github.com/fluid-cloudnative/fluid / MutatingHandler

Interface MutatingHandler

pkg/webhook/plugins/api/plugins_api.go:27–34  ·  view source on GitHub ↗

MutatingHandler defines the interface for mutating a pod, implementations should be thread(goroutine) safe.

Source from the content-addressed store, hash-verified

25
26// MutatingHandler defines the interface for mutating a pod, implementations should be thread(goroutine) safe.
27type MutatingHandler interface {
28 // Mutate injects affinity info into pod
29 // if a plugin return true, it means that no need to call other plugins
30 // map[string]base.RuntimeInfoInterface's key is pvcName
31 Mutate(*corev1.Pod, map[string]base.RuntimeInfoInterface) (shouldStop bool, err error)
32 // GetName returns the name of plugin
33 GetName() string
34}
35
36// RegistryHandler record the active plugins
37// including two kinds: plugins for pod with no dataset mounted and with dataset mounted

Callers 16

TestPodsFunction · 0.65
TestMutateOnlyRequiredFunction · 0.65
TestMutateOnlyPreferFunction · 0.65
TestTieredLocalityFunction · 0.65
TestMutateFunction · 0.65
TestMutateFunction · 0.65
TestPodsFunction · 0.65
TestGetRegistryHandlerFunction · 0.65
TestPluginFunction · 0.65

Implementers 7

NodeAffinityWithCachepkg/webhook/plugins/nodeaffinitywithca
FuseSidecarpkg/webhook/plugins/fusesidecar/fuse_s
DatasetUsageInjectorpkg/webhook/plugins/datasetusageinject
RequireNodeWithFusepkg/webhook/plugins/requirenodewithfus
MountPropagationInjectorpkg/webhook/plugins/mountpropagationin
PreferNodesWithoutCachepkg/webhook/plugins/prefernodeswithout
FilePrefetcherpkg/webhook/plugins/fileprefetcher/fil

Calls

no outgoing calls

Tested by

no test coverage detected