httpclient

package
v0.0.15 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2015 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultClient = http.Client{
	Transport: &http.Transport{
		TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
		Proxy:           http.ProxyFromEnvironment,
		Dial: (&net.Dialer{
			Timeout:   30 * time.Second,
			KeepAlive: 0,
		}).Dial,
		TLSHandshakeTimeout: 10 * time.Second,
	},
}

Functions

This section is empty.

Types

type HTTPClient

type HTTPClient interface {
	Post(endpoint string, payload []byte) (*http.Response, error)
	Put(endpoint string, payload []byte) (*http.Response, error)
	Get(endpoint string) (*http.Response, error)
	Delete(endpoint string) (*http.Response, error)
}

func NewHTTPClient

func NewHTTPClient(client http.Client, logger boshlog.Logger) HTTPClient

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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