Documentation ¶
Index ¶
- Variables
- func NewRequestDurationMetric(originalTransport http.RoundTripper, metric *prometheus.HistogramVec) http.RoundTripper
- func NewRequestDurationMetricNoEndpoint(originalTransport http.RoundTripper, metric *prometheus.HistogramVec) http.RoundTripper
- func NewRequestLogger(originalTransport http.RoundTripper, logger logger.Logger) http.RoundTripper
- func NewResponseLogger(originalTransport http.RoundTripper, logger logger.Logger) http.RoundTripper
- func NewTotalRequestCountMetric(originalTransport http.RoundTripper, metric *prometheus.CounterVec) http.RoundTripper
- func NewTotalRequestCountMetricNoEndpoint(originalTransport http.RoundTripper, metric *prometheus.CounterVec) http.RoundTripper
- func RequestDuration(appConfig *app.Config, informer logger.Informer) client.MiddlewareFunc
- func RequestDurationNoEndpoint(appConfig *app.Config, informer logger.Informer) client.MiddlewareFunc
- func RequestLogger(logger logger.Logger) client.MiddlewareFunc
- func ResponseLogger(logger logger.Logger) client.MiddlewareFunc
- func TotalRequestCount(appConfig *app.Config, informer logger.Informer) client.MiddlewareFunc
- func TotalRequestCountNoEndpoint(appConfig *app.Config, informer logger.Informer) client.MiddlewareFunc
Constants ¶
This section is empty.
Variables ¶
View Source
var Component = &app.Component{ Dependencies: app.Components{ logger.Component, client.Component, }, Run: app.Run(func(container container.Container) error { return container.Invoke(func(httpClient client.Doer, appConfig *app.Config, logger logger.Logger) { httpClient.Use( RequestLogger(logger), RequestDuration(appConfig, logger), TotalRequestCount(appConfig, logger), ) }) }), }
Functions ¶
func NewRequestDurationMetric ¶
func NewRequestDurationMetric(originalTransport http.RoundTripper, metric *prometheus.HistogramVec) http.RoundTripper
func NewRequestDurationMetricNoEndpoint ¶ added in v1.9.14
func NewRequestDurationMetricNoEndpoint(originalTransport http.RoundTripper, metric *prometheus.HistogramVec) http.RoundTripper
func NewRequestLogger ¶
func NewRequestLogger(originalTransport http.RoundTripper, logger logger.Logger) http.RoundTripper
func NewResponseLogger ¶ added in v1.8.12
func NewResponseLogger(originalTransport http.RoundTripper, logger logger.Logger) http.RoundTripper
func NewTotalRequestCountMetric ¶
func NewTotalRequestCountMetric(originalTransport http.RoundTripper, metric *prometheus.CounterVec) http.RoundTripper
func NewTotalRequestCountMetricNoEndpoint ¶ added in v1.9.14
func NewTotalRequestCountMetricNoEndpoint(originalTransport http.RoundTripper, metric *prometheus.CounterVec) http.RoundTripper
func RequestDuration ¶
func RequestDurationNoEndpoint ¶ added in v1.9.14
func RequestLogger ¶
func RequestLogger(logger logger.Logger) client.MiddlewareFunc
func ResponseLogger ¶ added in v1.8.12
func ResponseLogger(logger logger.Logger) client.MiddlewareFunc
func TotalRequestCount ¶
func TotalRequestCountNoEndpoint ¶ added in v1.9.14
Types ¶
This section is empty.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.