Documentation
¶
Index ¶
- Constants
- Variables
- func AddEncodingFlags(req *http.Request, flags EncodingFlags)
- func AddEncodingFlagsToContext(ctx context.Context, flags EncodingFlags) context.Context
- func ExtractActorPath(ctx context.Context) []string
- func ExtractHeader(ctx context.Context, name string) string
- func ExtractQueryMetricsMiddleware() middleware.Interface
- func ExtractQueryTagsFromContext(ctx context.Context) string
- func ExtractQueryTagsFromHTTP(req *http.Request) string
- func ExtractQueryTagsMiddleware() middleware.Interface
- func InjectActorPath(ctx context.Context, value string) context.Context
- func InjectHeader(ctx context.Context, key, value string) context.Context
- func InjectQueryTags(ctx context.Context, tags string) context.Context
- func PropagateHeadersMiddleware(headers ...string) middleware.Interface
- type EncodingFlag
- type EncodingFlags
- func ExtractEncodingFlags(req *http.Request) EncodingFlags
- func ExtractEncodingFlagsFromCtx(ctx context.Context) EncodingFlags
- func ExtractEncodingFlagsFromProto(req *httpgrpc.HTTPRequest) EncodingFlags
- func NewEncodingFlags(flags ...EncodingFlag) EncodingFlags
- func ParseEncodingFlags(rawFlags string) EncodingFlags
Constants ¶
View Source
const (
LokiEncodingFlagsHeader = "X-Loki-Response-Encoding-Flags"
FlagCategorizeLabels EncodingFlag = "categorize-labels"
EncodeFlagsDelimiter = ","
)
Variables ¶
View Source
var (
// LokiActorPathHeader is the name of the header e.g. used to enqueue requests in hierarchical queues.
LokiActorPathHeader = "X-Loki-Actor-Path"
LokiDisablePipelineWrappersHeader = "X-Loki-Disable-Pipeline-Wrappers"
// LokiActorPathDelimiter is the delimiter used to serialise the hierarchy of the actor.
LokiActorPathDelimiter = "|"
)
View Source
var (
QueryTagsHTTPHeader ctxKey = "X-Query-Tags"
QueryQueueTimeHTTPHeader ctxKey = "X-Query-Queue-Time"
)
Functions ¶
func AddEncodingFlags ¶
func AddEncodingFlags(req *http.Request, flags EncodingFlags)
func AddEncodingFlagsToContext ¶
func AddEncodingFlagsToContext(ctx context.Context, flags EncodingFlags) context.Context
func ExtractActorPath ¶
func ExtractActorPath(ctx context.Context) []string
func ExtractHeader ¶
func ExtractHeader(ctx context.Context, name string) string
func ExtractQueryMetricsMiddleware ¶
func ExtractQueryMetricsMiddleware() middleware.Interface
func ExtractQueryTagsFromContext ¶ added in v3.2.0
func ExtractQueryTagsFromContext(ctx context.Context) string
func ExtractQueryTagsFromHTTP ¶
func ExtractQueryTagsFromHTTP(req *http.Request) string
func ExtractQueryTagsMiddleware ¶
func ExtractQueryTagsMiddleware() middleware.Interface
func InjectActorPath ¶
func InjectActorPath(ctx context.Context, value string) context.Context
func InjectHeader ¶
func InjectHeader(ctx context.Context, key, value string) context.Context
func InjectQueryTags ¶
func InjectQueryTags(ctx context.Context, tags string) context.Context
func PropagateHeadersMiddleware ¶
func PropagateHeadersMiddleware(headers ...string) middleware.Interface
Types ¶
type EncodingFlag ¶
type EncodingFlag string
type EncodingFlags ¶
type EncodingFlags map[EncodingFlag]struct{}
func ExtractEncodingFlags ¶
func ExtractEncodingFlags(req *http.Request) EncodingFlags
func ExtractEncodingFlagsFromCtx ¶
func ExtractEncodingFlagsFromCtx(ctx context.Context) EncodingFlags
func ExtractEncodingFlagsFromProto ¶
func ExtractEncodingFlagsFromProto(req *httpgrpc.HTTPRequest) EncodingFlags
func NewEncodingFlags ¶
func NewEncodingFlags(flags ...EncodingFlag) EncodingFlags
func ParseEncodingFlags ¶
func ParseEncodingFlags(rawFlags string) EncodingFlags
Click to show internal directories.
Click to hide internal directories.