networking

package
Version: v0.0.0-...-e09e3e6 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ListenerProtocolUnknown is an unknown type of listener.
	ListenerProtocolUnknown = iota
	// ListenerProtocolTCP is a TCP listener.
	ListenerProtocolTCP
	// ListenerProtocolHTTP is an HTTP listener.
	ListenerProtocolHTTP
	// ListenerProtocolAuto enables auto protocol detection
	ListenerProtocolAuto
)
View Source
const (
	// TransportProtocolTCP is a TCP listener
	TransportProtocolTCP = iota
	// TransportProtocolQUIC is a QUIC listener
	TransportProtocolQUIC
)

Variables

This section is empty.

Functions

This section is empty.

Types

type FilterChain

type FilterChain struct {
	// FilterChainMatch is the match used to select the filter chain.
	FilterChainMatch *listener.FilterChainMatch
	// TLSContext is the TLS settings for this filter chains.
	TLSContext *tls.DownstreamTlsContext
	// ListenerProtocol indicates whether this filter chain is for HTTP or TCP
	// Note that HTTP filter chains can also have network filters
	ListenerProtocol ListenerProtocol
	// TransportProtocol indicates the type of transport used - TCP, UDP, QUIC
	// This would be TCP by default
	TransportProtocol TransportProtocol

	// HTTP is the set of HTTP filters for this filter chain
	HTTP []*http_conn.HttpFilter
	// TCP is the set of network (TCP) filters for this filter chain.
	TCP []*listener.Filter
}

FilterChain describes a set of filters (HTTP or TCP) with a shared TLS context.

type ListenerClass

type ListenerClass int

ListenerClass defines the class of the listener

const (
	ListenerClassUndefined ListenerClass = iota
	ListenerClassSidecarInbound
	ListenerClassSidecarOutbound
	ListenerClassGateway
)

type ListenerProtocol

type ListenerProtocol int

ListenerProtocol is the protocol associated with the listener.

func ModelProtocolToListenerProtocol

func ModelProtocolToListenerProtocol(p protocol.Instance,
	trafficDirection core.TrafficDirection,
) ListenerProtocol

ModelProtocolToListenerProtocol converts from a config.Protocol to its corresponding plugin.ListenerProtocol

type MutableObjects

type MutableObjects struct {
	// Listener is the listener being built. Must be initialized before Plugin methods are called.
	Listener *listener.Listener

	// FilterChains is the set of filter chains that will be attached to Listener.
	FilterChains []FilterChain
}

MutableObjects is a set of objects passed to On*Listener callbacks. Fields may be nil or empty. Any lists should not be overridden, but rather only appended to. Non-list fields may be mutated; however it's not recommended to do this since it can affect other plugins in the chain in unpredictable ways. TODO: do we need this now?

type TransportProtocol

type TransportProtocol uint8

func (TransportProtocol) String

func (tp TransportProtocol) String() string

func (TransportProtocol) ToEnvoySocketProtocol

func (tp TransportProtocol) ToEnvoySocketProtocol() core.SocketAddress_Protocol

Source Files

Directories

Path Synopsis
v1alpha3/loadbalancer
packages used for load balancer setting
packages used for load balancer setting
plugin

Jump to

Keyboard shortcuts

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