Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Transport ¶
Transport defines a transport with build-in connection counter Usage: func callback(n int64) { x.metrics.ConnectionGauge(n) } transport := conncount.NewTransport(logger, logFields, &http.Transport{}, callback) httpClient := &httpClient{Transport: transport}
func NewTransport ¶
NewTransport creates Transport with a connection counter. prev is a Transport to be wrapped. callback is a function to be called when connection counter changes.
Click to show internal directories.
Click to hide internal directories.