istio: Index | Files

package inmemory

import ""


Package Files


func BuildFieldPathMap Uses

func BuildFieldPathMap(yamlNode *yamlv3.Node, startLineNum int, curPath string, fieldPathMap map[string]int)

BuildFieldPathMap builds the flat map for each field of the YAML resource

type KubeSource Uses

type KubeSource struct {
    // contains filtered or unexported fields

KubeSource is an in-memory source implementation that can handle K8s style resources.

func NewKubeSource Uses

func NewKubeSource(schemas collection.Schemas) *KubeSource

NewKubeSource returns a new in-memory Source that works with Kubernetes resources.

func (*KubeSource) ApplyContent Uses

func (s *KubeSource) ApplyContent(name, yamlText string) error

ApplyContent applies the given yamltext to this source. The content is tracked with the given name. If ApplyContent gets called multiple times with the same name, the contents applied by the previous incarnation will be overwritten or removed, depending on the new content. Returns an error if any were encountered, but that still may represent a partial success

func (*KubeSource) Clear Uses

func (s *KubeSource) Clear()

Clear the contents of this source

func (*KubeSource) ContentNames Uses

func (s *KubeSource) ContentNames() map[string]struct{}

ContentNames returns the names known to this source.

func (*KubeSource) Dispatch Uses

func (s *KubeSource) Dispatch(h event.Handler)

Dispatch implements processor.Source

func (*KubeSource) Get Uses

func (s *KubeSource) Get(collection collection.Name) *inmemory.Collection

Get returns the named collection.

func (*KubeSource) RemoveContent Uses

func (s *KubeSource) RemoveContent(name string)

RemoveContent removes the content for the given name

func (*KubeSource) SetDefaultNamespace Uses

func (s *KubeSource) SetDefaultNamespace(defaultNs resource.Namespace)

SetDefaultNamespace enables injecting a default namespace for resources where none is already specified

func (*KubeSource) Start Uses

func (s *KubeSource) Start()

Start implements processor.Source

func (*KubeSource) Stop Uses

func (s *KubeSource) Stop()

Stop implements processor.Source

Package inmemory imports 20 packages (graph) and is imported by 1 packages. Updated 2020-11-14. Refresh now. Tools for package owners.