logger

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: May 8, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildLogger

func BuildLogger(logLevel string) lager.Logger

BuildLogger for project

func FormatHeaders

func FormatHeaders(headers http.Header, seperator string) string

FormatHeaders processes a headers object plus a deliminator, returning a string

func RedactHeaders

func RedactHeaders(headers http.Header) (processedHeaders []string)

RedactHeaders processes a headers object, returning a redacted list

Types

type LogRoundTripper

type LogRoundTripper struct {
	Rt      http.RoundTripper
	OsDebug bool
}

LogRoundTripper satisfies the http.RoundTripper interface and is used to customize the default http client RoundTripper to allow for logging.

func (*LogRoundTripper) RoundTrip

func (lrt *LogRoundTripper) RoundTrip(request *http.Request) (*http.Response, error)

RoundTrip performs a round-trip HTTP request and logs relevant information about it.

Jump to

Keyboard shortcuts

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