1.6 KiB
1.6 KiB
007 — FilterBar query integration
Summary
Wire the parsed filter AST into actual log/timeline queries against the engine, so FilterBar's syntax (not just a naive substring match) drives what's shown in LogPreview and LogTimeline.
Scope
- Evaluator that walks the AST from 005, resolving
regex(...)against log text andmetric_name[param] <op> valueagainst bucket data (004), using datetime literals resolved via 006. - New/extended
EngineQuery::Logs(andTimeline) filter parameter that accepts the compiled filter, evaluated inside the engine's single-owner loop (per the README's "engine is sole owner of the btreemap" architecture — don't evaluate against a copy). sequence/timestampreserved-metric comparisons map directly to theIngestedLogkey fields rather than a declared metric lookup.- API layer: accept the raw filter string, parse it (return 4xx on parse error), compile to whatever the engine query needs, send to engine.
Acceptance criteria
GET /api/logs?filter=...and the timeline equivalent apply the full filter language, not just substring matching.- A filter combining a regex clause and a metric comparison with
and/orreturns correct results against a seeded log+metric fixture. - Malformed filter strings return a 4xx with the parser's error message.