package podutil
import "k8s.io/kubernetes/contrib/mesos/pkg/podutil"
podutil contains utilities for reading, writing and filtering streams and lists of api.Pod objects.
Index ¶
- func Annotate(meta *api.ObjectMeta, kv map[string]string)
- func Gunzip(gzipped []byte) <-chan *api.Pod
- func Gzip(pods <-chan *api.Pod) ([]byte, error)
- func List(pods <-chan *api.Pod) *api.PodList
- func ReadFromDir(dirpath string) (<-chan *api.Pod, <-chan error)
- func Stream(list *api.PodList, err error) <-chan *api.Pod
- func WriteToDir(pods <-chan *api.Pod, destDir string) error
- type FilterFunc
- func Annotator(m map[string]string) FilterFunc
- func (filter FilterFunc) Do(in <-chan *api.Pod) <-chan *api.Pod
- type Filters
Functions ¶
func Annotate ¶
func Annotate(meta *api.ObjectMeta, kv map[string]string)
Annotate safely copies annotation metadata from kv to meta.Annotations.
func Gunzip ¶
func Gzip ¶
func List ¶
List reads every pod from the pods chan and returns them all in an api.PodList
func ReadFromDir ¶
func Stream ¶
Stream returns a chan of pods that yields each pod from the given list. No pods are yielded if err is non-nil.
func WriteToDir ¶
Types ¶
type FilterFunc ¶
func Annotator ¶
func Annotator(m map[string]string) FilterFunc
Annotator returns a filter that copies annotations from map m into a pod
func (FilterFunc) Do ¶
func (filter FilterFunc) Do(in <-chan *api.Pod) <-chan *api.Pod
type Filters ¶
type Filters []FilterFunc
Source Files ¶
doc.go filters.go gzip.go io.go
- Version
- v1.2.0-alpha.5
- Published
- Dec 15, 2015
- Platform
- js/wasm
- Imports
- 12 packages
- Last checked
- 2 minutes ago –
Tools for package owners.