subsetmapper

package
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 31, 2020 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const RefreshPeriod = 30 * time.Second

Variables

This section is empty.

Functions

func ApplyLabelsToInstance

func ApplyLabelsToInstance(labels []string, namespace string) error

ApplyLabelsToInstance generate and apply instance crd to local configured kubectl This is a temporary solution until istio fixes destination labels This pull request fixes it: https://github.com/istio/api/pull/925 but it isn't arrived at main release, it should be tested with new release

func GenerateInstanceWithLogEntryTemplate

func GenerateInstanceWithLogEntryTemplate(labels []string, namespace string) *models.Instance

GenerateInstanceWithLogEntryTemplate generate instance template with given labels and namespace

Types

type SubsetInfo

type SubsetInfo struct {
	DestinationName string
	SubsetWithPorts clientmodels.SubsetToPorts
}

type SubsetMapper added in v0.0.3

type SubsetMapper struct {
	DestinationsSubsetMap0 *clientmodels.DestinationsSubsetsMap
	DestinationsSubsetMap1 *clientmodels.DestinationsSubsetsMap
	// contains filtered or unexported fields
}

func New added in v0.0.3

func New() *SubsetMapper

func (*SubsetMapper) GetDestinationsSubsetsMap added in v0.0.3

func (sm *SubsetMapper) GetDestinationsSubsetsMap() *clientmodels.DestinationsSubsetsMap

GetDesitinationsSubsetsMap returns active subset map

func (*SubsetMapper) GetRestClient added in v0.0.3

func (sm *SubsetMapper) GetRestClient() (client.IRestClient, error)

GetRestClient gets or creates rest client

func (*SubsetMapper) GetSubsetByLabels added in v0.0.3

func (sm *SubsetMapper) GetSubsetByLabels(destination string, labels map[string]string) []SubsetInfo

GetSubsetByLabels return all possible subsets for given labels

func (*SubsetMapper) RefreshDestinationsSubsetsMap added in v0.0.3

func (sm *SubsetMapper) RefreshDestinationsSubsetsMap() error

RefreshDestinationsSubsetsMap updates the subset map

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL