Documentation ¶
Index ¶
- Constants
- func NewRoundTripper(next http.RoundTripper, middlewares ...Middleware) http.RoundTripper
- func NewTripperware(cfg Config, logger log.Logger, registerer prometheus.Registerer) (queryrange.Tripperware, error)
- type Config
- type CortexNoQuerierLimits
- type Handler
- type Middleware
- type MiddlewareFunc
- type RequestResponse
Constants ¶
View Source
const ( MinQueryShards = 2 MaxQueryShards = 256 )
Variables ¶
This section is empty.
Functions ¶
func NewRoundTripper ¶
func NewRoundTripper(next http.RoundTripper, middlewares ...Middleware) http.RoundTripper
NewRoundTripper merges a set of middlewares into an handler, then inject it into the `next` roundtripper
func NewTripperware ¶
func NewTripperware(cfg Config, logger log.Logger, registerer prometheus.Registerer) (queryrange.Tripperware, error)
NewTripperware returns a Tripperware configured with a middleware to split requests
Types ¶
type Config ¶
type Config struct { Config frontend.CombinedFrontendConfig `yaml:",inline"` QueryShards int `yaml:"query_shards,omitempty"` }
type CortexNoQuerierLimits ¶ added in v0.6.0
type CortexNoQuerierLimits struct{}
func (CortexNoQuerierLimits) MaxQueriersPerUser ¶ added in v0.6.0
func (CortexNoQuerierLimits) MaxQueriersPerUser(user string) int
type Middleware ¶
func Deduper ¶ added in v1.0.0
func Deduper(logger log.Logger) Middleware
func MergeMiddlewares ¶
func MergeMiddlewares(middleware ...Middleware) Middleware
func ShardingWare ¶
func ShardingWare(queryShards int, logger log.Logger) Middleware
type MiddlewareFunc ¶
MiddlewareFunc is like http.HandlerFunc, but for Middleware.
func (MiddlewareFunc) Wrap ¶
func (q MiddlewareFunc) Wrap(h Handler) Handler
Wrap implements Middleware.
Click to show internal directories.
Click to hide internal directories.