istio: istio.io/istio/pkg/config/mesh Index | Files

package mesh

import "istio.io/istio/pkg/config/mesh"

Index

Package Files

mesh.go networks_watcher.go watcher.go

func ApplyMeshConfig Uses

func ApplyMeshConfig(yaml string, defaultConfig meshconfig.MeshConfig) (*meshconfig.MeshConfig, error)

ApplyMeshConfig returns a new MeshConfig decoded from the input YAML with the provided defaults applied to omitted configuration values.

func ApplyMeshConfigDefaults Uses

func ApplyMeshConfigDefaults(yaml string) (*meshconfig.MeshConfig, error)

ApplyMeshConfigDefaults returns a new MeshConfig decoded from the input YAML with defaults applied to omitted configuration values.

func DefaultMeshConfig Uses

func DefaultMeshConfig() meshconfig.MeshConfig

DefaultMeshConfig configuration

func DefaultProxyConfig Uses

func DefaultProxyConfig() meshconfig.ProxyConfig

DefaultProxyConfig for individual proxies

func EmptyMeshNetworks Uses

func EmptyMeshNetworks() meshconfig.MeshNetworks

EmptyMeshNetworks configuration with no networks

func ParseMeshNetworks Uses

func ParseMeshNetworks(yaml string) (*meshconfig.MeshNetworks, error)

ParseMeshNetworks returns a new MeshNetworks decoded from the input YAML.

func ReadMeshConfig Uses

func ReadMeshConfig(filename string) (*meshconfig.MeshConfig, error)

ReadMeshConfig gets mesh configuration from a config file

func ReadMeshNetworks Uses

func ReadMeshNetworks(filename string) (*meshconfig.MeshNetworks, error)

ReadMeshNetworks gets mesh networks configuration from a config file

func ResolveHostsInNetworksConfig Uses

func ResolveHostsInNetworksConfig(config *meshconfig.MeshNetworks)

ResolveHostsInNetworksConfig will go through the Gateways addresses for all networks in the config and if it's not an IP address it will try to lookup that hostname and replace it with the IP address in the config

type Holder Uses

type Holder interface {
    Mesh() *meshconfig.MeshConfig
}

Holder of a mesh configuration.

type NetworksHolder Uses

type NetworksHolder interface {
    Networks() *meshconfig.MeshNetworks
}

NetworksHolder is a holder of a mesh networks configuration.

type NetworksWatcher Uses

type NetworksWatcher interface {
    NetworksHolder

    AddNetworksHandler(func())
}

NetworkWatcher watches changes to the mesh networks config.

func NewFixedNetworksWatcher Uses

func NewFixedNetworksWatcher(networks *meshconfig.MeshNetworks) NetworksWatcher

NewFixedNetworksWatcher creates a new NetworksWatcher that always returns the given config. It will never fire any events, since the config never changes.

func NewNetworksWatcher Uses

func NewNetworksWatcher(fileWatcher filewatcher.FileWatcher, filename string) (NetworksWatcher, error)

NewNetworksWatcher creates a new watcher for changes to the given networks config file.

type Watcher Uses

type Watcher interface {
    Holder

    // AddMeshHandler registers a callback handler for changes to the mesh config.
    AddMeshHandler(func())
}

Watcher is a Holder whose mesh config can be updated asynchronously.

func NewFixedWatcher Uses

func NewFixedWatcher(mesh *meshconfig.MeshConfig) Watcher

NewFixedWatcher creates a new Watcher that always returns the given mesh config. It will never fire any events, since the config never changes.

func NewWatcher Uses

func NewWatcher(fileWatcher filewatcher.FileWatcher, filename string) (Watcher, error)

NewWatcher creates a new Watcher for changes to the given mesh config file. Returns an error if the given file does not exist or failed during parsing.

Package mesh imports 17 packages (graph) and is imported by 24 packages. Updated 2020-01-18. Refresh now. Tools for package owners.