app

package
v0.0.0-...-a8e6978 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2023 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultStreamReceiveWindow     = 15728640 // 15 MB/s
	DefaultConnectionReceiveWindow = 67108864 // 64 MB/s
	DefaultMaxIncomingStreams      = 1024

	DefaultALPN = "h3"

	ServerMaxIdleTimeoutSec = 60
)

Variables

This section is empty.

Functions

func Run

func Run(config *ServerConfig, usersService *service.UsersService)

Types

type ServerConfig

type ServerConfig struct {
	Listen   string `json:"listen"`
	Protocol string `json:"protocol"`
	CertFile string `json:"cert"`
	KeyFile  string `json:"key"`
	// Optional below
	UpMbps              int    `json:"up_mbps"`
	DownMbps            int    `json:"down_mbps"`
	DisableUDP          bool   `json:"disable_udp"`
	Obfs                string `json:"obfs"`
	ALPN                string `json:"alpn"`
	ReceiveWindowConn   uint64 `json:"recv_window_conn"`
	ReceiveWindowClient uint64 `json:"recv_window_client"`
	MaxConnClient       int    `json:"max_conn_client"`
	DisableMTUDiscovery bool   `json:"disable_mtu_discovery"`
}

func (*ServerConfig) Check

func (c *ServerConfig) Check() error

func (*ServerConfig) Fill

func (c *ServerConfig) Fill()

func (*ServerConfig) Speed

func (c *ServerConfig) Speed() (uint64, uint64, error)

func (*ServerConfig) String

func (c *ServerConfig) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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