config

package
v0.0.0-...-cb92cc7 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Endpoint = struct {
	Timeout  time.Duration
	MaxRetry int
}{
	Timeout:  time.Second * 15,
	MaxRetry: 5,
}
View Source
var Router = struct {
	StopApplyWhenError bool
	FollowRedirect     bool
}{
	StopApplyWhenError: false,
	FollowRedirect:     true,
}
View Source
var Server = struct {
	Address           string
	Port              uint32
	MaxCurrentStream  uint32
	ReadTimeout       time.Duration
	ReadHeaderTimeout time.Duration
	WriteTimeout      time.Duration
	IdleTimeout       time.Duration
}{
	Address:           "0.0.0.0",
	Port:              8081,
	MaxCurrentStream:  math.MaxInt32,
	ReadTimeout:       time.Second * 15,
	ReadHeaderTimeout: time.Second * 10,
	WriteTimeout:      time.Second * 15,
	IdleTimeout:       time.Second * 120,
}
View Source
var Transport = struct {
	Timeout                   time.Duration
	KeepAlive                 time.Duration
	MaxIdleConnections        int
	MaxIdleConnectionsPerHost int
	MaxConnectionsPerHost     int
	DisableCompression        bool
	IdleConnectionTimeout     time.Duration
	TLSHandshakeTimeout       time.Duration
	ExceptContinueTimeout     time.Duration
}{
	Timeout:                   time.Second * 15,
	KeepAlive:                 time.Second * 30,
	MaxIdleConnections:        10000,
	MaxIdleConnectionsPerHost: 1000,
	MaxConnectionsPerHost:     1000,
	DisableCompression:        true,
	IdleConnectionTimeout:     time.Second * 90,
	TLSHandshakeTimeout:       time.Second * 10,
	ExceptContinueTimeout:     time.Second * 1,
}

Functions

func ServerListenAddress

func ServerListenAddress() string

Types

type Protocol

type Protocol int32

Jump to

Keyboard shortcuts

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