networking

package
v1.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2023 License: Apache-2.0 Imports: 11 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
)
View Source
const (
	NoTunnelTypeName = "notunnel"
	H2TunnelTypeName = "H2Tunnel"
)

Variables

This section is empty.

Functions

func MessageToAny

func MessageToAny(msg proto.Message) *anypb.Any

MessageToAny converts from proto message to proto Any

func MessageToAnyWithError

func MessageToAnyWithError(msg proto.Message) (*anypb.Any, error)

MessageToAnyWithError converts from proto message to proto Any

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

type TunnelAbility

type TunnelAbility int

func MakeTunnelAbility

func MakeTunnelAbility(ttypes ...TunnelType) TunnelAbility

func (TunnelAbility) SupportH2Tunnel

func (t TunnelAbility) SupportH2Tunnel() bool

type TunnelType

type TunnelType int
const (
	// Bind the no tunnel support to a name.
	NoTunnel TunnelType = 0
	// Enumeration of tunnel type below. Each type should own a unique bit field.
	H2Tunnel TunnelType = 1 << 0
)

func (TunnelType) ToString

func (t TunnelType) ToString() string

Directories

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

Jump to

Keyboard shortcuts

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