Results Cache
Results cache is the final layer in Dremio's query acceleration stack. Where Reflections accelerate queries by precomputing results that can satisfy a broad family of similar queries, results cache handles pure repetition: when the same deterministic query runs again against unchanged data, Dremio returns the cached result directly without re-executing.
Results cache works out of the box, requires no configuration, and always returns correct results regardless of whether a cache hit occurs.
Results cache is client-agnostic. A query executed in the Dremio console will produce a cache hit even if re-run through JDBC, ODBC, REST, or Arrow Flight. For a cache hit to occur, the query plan must be identical to the cached version. Any change to the schema or dataset generates a new query plan and invalidates the cache.
Cases Supported By Results Cache
Query results are cached when all of the following are true:
- The SQL statement is a
SELECTstatement. - The query reads from an Iceberg or Parquet dataset, or from a raw Reflection defined on other supported data sources and formats (such as relational databases,
CSV,JSON, orTEXT). - The query does not contain dynamic functions such as
QUERY_USER,IS_MEMBER,RAND,CURRENT_DATE, orNOW. - The query does not reference
SYSorINFORMATION_SCHEMAtables, or use external query. - The result set is 20 MB or less.
- The query is not executed as a preview in the Dremio console.
View Whether Queries Used Results Cache
To find whether a query was accelerated by the results cache:
- On the Jobs page, find the job and look for
next to it, which indicates acceleration by either Reflections or results cache. - Click the row to view the job summary. The summary pane on the right shows whether the query was accelerated by results cache or Reflections.
Storage
Cached results are stored in the project store alongside metadata and Reflections. Executors write cache entries as Arrow data files and read them when processing queries that result in a cache hit. Coordinators manage the deletion of expired cache files. Results cache supports coordinator scale-out, so newly added coordinators can benefit immediately from previously cached results.
Deletion
A background task running on one of the Dremio coordinators handles cache expiration. It runs every hour, marks cache entries not accessed in the past 24 hours as expired, and deletes them along with their associated files.
Considerations and Limitations
SQL queries executed through the Dremio console or a REST client that access the cache will rewrite the cached query results to the job results store to enable pagination.