loggingclient

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: May 16, 2021 License: MIT Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

New wraps an upstream client and logs all requests made to it.

func NewWithFilter added in v0.3.0

func NewWithFilter(upstream httpclient.HttpClient, logger logging.Logger, filter logging.Filter) httpclient.HttpClient

Types

type LoggingClient

type LoggingClient struct {
	// contains filtered or unexported fields
}

LoggingClient is a HttpClient with a pluggable logger.

func (*LoggingClient) Do

func (lc *LoggingClient) Do(req *http.Request) (*http.Response, error)

func (*LoggingClient) SetCheckRedirect added in v0.0.6

func (lc *LoggingClient) SetCheckRedirect(fn func(req *http.Request, via []*http.Request) error)

Jump to

Keyboard shortcuts

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