Expand description
Query Classification Cache
This module caches pre-computed characteristics of SELECT statements to avoid repeated AST traversals. For example, determining if a query has aggregation requires walking the entire SELECT column list - we cache this result.
§Performance Impact
Before: has_aggregation() called 3-5 times per query, each traversing all columns After: Single traversal on first access, O(1) lookup thereafter
Structs§
- Query
Classification - Pre-computed characteristics of a SELECT statement.
Functions§
- clear_
classification_ cache - Clear the classification cache. Call on database drop to release memory.
- get_
classification - Get or compute the classification for a SELECT statement