Documentation ¶
Index ¶
- Constants
- func DataSourceMetricsMiddleware() sdkhttpclient.Middleware
- func New(cfg *setting.Cfg, validator models.PluginRequestValidator, ...) *sdkhttpclient.Provider
- func RedirectLimitMiddleware(reqValidator models.PluginRequestValidator) sdkhttpclient.Middleware
- func ResponseLimitMiddleware(limit int64) sdkhttpclient.Middleware
- func SetUserAgentMiddleware(userAgent string) httpclient.Middleware
- func SigV4Middleware(verboseLogging bool) httpclient.Middleware
- func TracingMiddleware(logger log.Logger, tracer tracing.Tracer) httpclient.Middleware
Constants ¶
View Source
const DataSourceMetricsMiddlewareName = "metrics"
View Source
const HostRedirectValidationMiddlewareName = "host-redirect-validation"
View Source
const ResponseLimitMiddlewareName = "response-limit"
ResponseLimitMiddlewareName is the middleware name used by ResponseLimitMiddleware.
View Source
const SetUserAgentMiddlewareName = "user-agent"
SetUserAgentMiddlewareName is the middleware name used by SetUserAgentMiddleware.
View Source
const SigV4MiddlewareName = "sigv4"
SigV4MiddlewareName the middleware name used by SigV4Middleware.
View Source
const (
TracingMiddlewareName = "tracing"
)
Variables ¶
This section is empty.
Functions ¶
func DataSourceMetricsMiddleware ¶
func DataSourceMetricsMiddleware() sdkhttpclient.Middleware
func New ¶
func New(cfg *setting.Cfg, validator models.PluginRequestValidator, tracer tracing.Tracer) *sdkhttpclient.Provider
New creates a new HTTP client provider with pre-configured middlewares.
func RedirectLimitMiddleware ¶
func RedirectLimitMiddleware(reqValidator models.PluginRequestValidator) sdkhttpclient.Middleware
func ResponseLimitMiddleware ¶
func ResponseLimitMiddleware(limit int64) sdkhttpclient.Middleware
func SetUserAgentMiddleware ¶
func SetUserAgentMiddleware(userAgent string) httpclient.Middleware
SetUserAgentMiddleware is middleware that sets the HTTP header User-Agent on the outgoing request. If User-Agent already set, it will not be overridden by this middleware.
func SigV4Middleware ¶
func SigV4Middleware(verboseLogging bool) httpclient.Middleware
SigV4Middleware applies AWS Signature Version 4 request signing for the outgoing request.
func TracingMiddleware ¶
func TracingMiddleware(logger log.Logger, tracer tracing.Tracer) httpclient.Middleware
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.