Skip to content

Conversation

@ForeverAngry
Copy link
Contributor

Closes #2147

  • Implement ResidualEvaluatorCache with LRU eviction and thread safety
  • Cache evaluators by partition spec, expression, case sensitivity, and schema

Rationale for this change

For queries, the same combinations of (partition spec, expression, case sensitivity, schema) are evaluated repeatedly, causing unnecessary computational overhead and increased query latency.

Are these changes tested?

Yes, using the existing test cases as they seemed sufficient for the changes.

Are there any user-facing changes?

No.

Fixes apache#2147

- Implement ResidualEvaluatorCache with LRU eviction and thread safety
- Cache evaluators by partition spec, expression, case sensitivity, and schema
- Fix mypy type annotations and add type ignore for cachetools decorator
@ForeverAngry ForeverAngry force-pushed the feat-cache-residual-evaluator branch from 55e53d0 to 0ec381e Compare November 7, 2025 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cache ResidualEvaluator

1 participant