MCPcopy
hub / github.com/grafana/tempo / Parse

Function Parse

pkg/traceql/parse.go:26–29  ·  pkg/traceql/parse.go::Parse

Parse parses a TraceQL query string and applies AST transformations according to opts. Options specific to metrics queries (e.g. WithSpanOnlyFetch) are ignored here.

(s string, opts ...CompileOption)

Source from the content-addressed store, hash-verified

24// Parse parses a TraceQL query string and applies AST transformations according to opts.
25// Options specific to metrics queries (e.g. WithSpanOnlyFetch) are ignored here.
26func Parse(s string, opts ...CompileOption) (expr *RootExpr, err error) {
27 cfg := applyCompileOptions(opts...)
28 return parseInternal(s, cfg.skipTransformations, cfg.allowUnsafeHints)
29}
30
31// ParseNoOptimizations parses a TraceQL query without applying any AST transformations.
32// Use for contexts where only hints or query structure are inspected and not executed, like hint extraction, validation, etc.

Calls 2

applyCompileOptionsFunction · 0.85
parseInternalFunction · 0.85