server

package
v0.0.0-...-3fd74df Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Connection

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

func NewConnection

func NewConnection(logger *zap.Logger, connectionType ConnectionType, name string) *Connection

func (*Connection) Close

func (connection *Connection) Close(ctx context.Context) error

func (*Connection) Connect

func (connection *Connection) Connect(
	ctx context.Context,
	hostAddress string) error

func (*Connection) ExecuteQuery

func (connection *Connection) ExecuteQuery(
	ctx context.Context,
	query string,
	writer wire.DataWriter) error

type ConnectionType

type ConnectionType int
const (
	Primary ConnectionType = iota
	Mirror
)

type ProxyServer

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

func NewProxyServer

func NewProxyServer(logger *zap.Logger) *ProxyServer

func (*ProxyServer) Close

func (server *ProxyServer) Close(ctx context.Context) error

func (*ProxyServer) ListenAndServe

func (server *ProxyServer) ListenAndServe(
	ctx context.Context,
	listenAddress string,
	primaryAddress string,
	mirrorAddresses []string) error

Jump to

Keyboard shortcuts

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