xrm

package
v0.0.0-...-5a11d6c Latest Latest
Warning

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

Go to latest
Published: May 17, 2023 License: GPL-3.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClusterName  = "example_proxy_cluster"
	RouteName    = "local_route"
	ListenerName = "listener_0"
	ListenerPort = 30001
	UpstreamHost = "192.168.122.1"
	UpstreamPort = 3000
)

Variables

This section is empty.

Functions

func GenerateSnapshot

func GenerateSnapshot() *cachev3.Snapshot

GenerateSnapshot TODO 这里创建了 默认的 资源 后续应该改为空资源, 因为 envoy 连接后给的配置为空.

func Init

func Init() error

func RunServer

func RunServer(srv server.Server, address string)

RunServer starts an xDS server at the given port.

Types

type Logger

type Logger struct {
	Debug bool
}

func (Logger) Debugf

func (logger Logger) Debugf(format string, args ...interface{})

Log to stdout only if Debug is true.

func (Logger) Errorf

func (logger Logger) Errorf(format string, args ...interface{})

Log to stdout always.

func (Logger) Infof

func (logger Logger) Infof(format string, args ...interface{})

Log to stdout only if Debug is true.

func (Logger) Warnf

func (logger Logger) Warnf(format string, args ...interface{})

Log to stdout always.

type Server

type Server struct {
	// contains filtered or unexported fields
}

func (*Server) Run

func (s *Server) Run(port uint)

Jump to

Keyboard shortcuts

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