Documentation
¶
Index ¶
Constants ¶
View Source
const (
// if we don't use this source then the kubelet will do funny, mirror things. we alias
// this here for convenience. see the docs for Source for additional explanation.
// @see ConfigSourceAnnotationKey
MesosSource = kubetypes.ApiserverSource
)
Variables ¶
This section is empty.
Functions ¶
func Mesos ¶
func Mesos(
stop <-chan struct{},
out chan<- interface{},
podWatch *cache.ListWatch,
registry executor.Registry,
options ...Option,
)
Mesos spawns a new pod source that watches API server for changes and collaborates with executor.Registry to generate api.Pod objects in a fashion that's very Mesos-aware.
Types ¶
type Filter ¶
type Filter interface {
// Before is invoked before any pods are evaluated
Before(podCount int)
// Accept returns true if this pod should be accepted by the source; a value
// of false results in the pod appearing to have been removed from apiserver.
// If true, the caller should use the output pod value for the remainder of
// the processing task. If false then the output pod value may be nil.
Accept(*api.Pod) (*api.Pod, bool)
// After is invoked after all pods have been evaluated
After()
}
Filter is invoked for each snapshot of pod state that passes through this source
type FilterFunc ¶
type FilterFunc func(*api.Pod) (*api.Pod, bool)
FilterFunc is a simplified Filter implementation that only implements Filter.Accept, its Before and After implementations are noop.
type Option ¶
type Option func(*Source)
func ContainerEnvOverlay ¶
func ContainerEnvOverlay(env []api.EnvVar) Option
Click to show internal directories.
Click to hide internal directories.