translator

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2023 License: Apache-2.0 Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildRateLimitServiceConfig added in v0.3.0

func BuildRateLimitServiceConfig(irListener *ir.HTTPListener) *ratelimitserviceconfig.YamlRoot

BuildRateLimitServiceConfig builds the rate limit service configuration based on https://github.com/envoyproxy/ratelimit#the-configuration-format

func GetRateLimitServiceConfigStr added in v0.3.0

func GetRateLimitServiceConfigStr(yamlRoot *ratelimitserviceconfig.YamlRoot) (string, error)

GetRateLimitServiceConfigStr returns the YAML string for the rate limit service configuration.

Types

type EndpointType added in v0.4.0

type EndpointType int
const (
	DefaultEndpointType EndpointType = iota
	Static
	EDS
)

type GlobalRateLimitSettings added in v0.3.0

type GlobalRateLimitSettings struct {
	// ServiceURL is the URL of the global
	// rate limit service.
	ServiceURL string
}

type ProtocolType added in v0.4.0

type ProtocolType int
const (
	DefaultProtocol ProtocolType = iota
	TCP
	UDP
	HTTP
	HTTP2
)

type Translator added in v0.3.0

type Translator struct {
	// GlobalRateLimit holds the global rate limit settings
	// required during xds translation.
	GlobalRateLimit *GlobalRateLimitSettings

	// ExtensionManager holds the config for interacting with extensions when generating xDS
	// resources. Only required during xds translation.
	ExtensionManager *extensionTypes.Manager
}

Translator translates the xDS IR into xDS resources.

func (*Translator) Translate added in v0.3.0

func (t *Translator) Translate(ir *ir.Xds) (*types.ResourceVersionTable, error)

Translate translates the XDS IR into xDS resources

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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