net

package
v1.11.1 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProxyEnvVar   string        = "HTTP_PROXY"
	Nameserver    string        = "8.8.4.4:53"
	DialerTimeout time.Duration = time.Millisecond * time.Duration(10000)
)

Variables

This section is empty.

Functions

func NewHttpClient

func NewHttpClient() *http.Client

NewHttpClient returns an initialized HTTP Client that uses an external nameserver to help avoid negative caching and if detected will make use of any proxy found in the environment

func NewResolver

func NewResolver() *net.Resolver

NewResolver returns an initialized Resolver that uses an external nameserver to help avoid negative caching

Types

This section is empty.

Jump to

Keyboard shortcuts

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