Mohan
08/24/2026, 6:56 PMRocky
08/24/2026, 6:57 PMINSERT) commits, the FE atomically updates the table's version. Every query first consults the FE to get the current list of active segment files.
* Consistency: Because the BE only queries the specific file versions requested by the FE, it is impossible for the cache to return "old" data for a table that has been updated.
3. Cache Retention Strategy
You mentioned "how is it controlled," and there is one specific property that affects which data stays in the cache:
* datacache.partition_duration: This table property defines the "hot data" window. For example, if set to 7d, StarRocks will prioritize caching blocks from partitions created within the last 7 days. Data older than this may not be cached or will be evicted sooner.
* LRU Eviction: Aside from the partition duration, the cache is managed by an LRU (Least Recently Used) mechanism. If the disk cache reaches its limit (controlled by datacache_disk_size), older or less frequently accessed blocks are evicted to make room for new ones.
Summary
* Will it get from cache? Yes, if the data is still the "latest" version according to the FE.
* Will it look at the bucket? Yes, if new data has been committed or if the cached blocks were evicted due to space constraints.
* Freshness guarantee: You always get the latest data. The cache only accelerates the retrieval of the files that the FE identifies as current.
Note: In StarRocks 4.0, the "Data Cache" system uniformly manages both Page Cache (memory) and Block Cache (disk) for even better efficiency.
References
• deployment/shared_data/feature-support-shared-data.md
• administration/management/BE_configuration.md
• data_source/data_cache.md
• data_source/data_cache_troubleshooting.md