Files
greptimedb/mito2/cache/index.html
T

2 lines
19 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Cache for the engine."><title>mito2::cache - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Italic-81dc35de.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-MediumItalic-ccf7e434.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2"href="../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../../static.files/rustdoc-1ed95124.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="mito2" data-themes="" data-resource-suffix="" data-rustdoc-version="1.98.1 (48a229cea 2026-09-01)" data-channel="1.98.1" data-search-js="search-9944d736.js" data-stringdex-js="stringdex-2da4960a.js" data-settings-js="settings-170eb4bf.js" ><script src="../../static.files/storage-41dd4d93.js"></script><script defer src="../sidebar-items.js"></script><script defer src="../../static.files/main-417ebf0a.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-f7c3ffd8.css"></noscript><link rel="alternate icon" type="image/png" href="../../static.files/favicon-32x32-eab170b8.png"><link rel="icon" type="image/svg+xml" href="../../static.files/favicon-044be391.svg"></head><body class="rustdoc mod"><a class="skip-main-content" href="#main-content">Skip to main content</a><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><rustdoc-topbar><h2><a href="#">Module cache</a></h2></rustdoc-topbar><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../mito2/index.html">mito2</a><span class="version">1.4.0-alpha.0</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Module cache</a></h2><h3><a href="#modules">Module Items</a></h3><ul class="block"><li><a href="#modules" title="Modules">Modules</a></li><li><a href="#structs" title="Structs">Structs</a></li><li><a href="#enums" title="Enums">Enums</a></li><li><a href="#constants" title="Constants">Constants</a></li><li><a href="#traits" title="Traits">Traits</a></li><li><a href="#functions" title="Functions">Functions</a></li><li><a href="#types" title="Type Aliases">Type Aliases</a></li></ul></section><div id="rustdoc-modnav"><h2 class="in-crate"><a href="../index.html">In crate mito2</a></h2></div></div></nav><div class="sidebar-resizer" title="Drag to resize sidebar"></div><main><div class="width-limiter"><section id="main-content" class="content" tabindex="-1"><div class="main-heading"><div class="rustdoc-breadcrumbs"><a href="../index.html">mito2</a></div><h1>Module <span>cache</span>&nbsp;<button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../../src/mito2/cache.rs.html#15-3038">Source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Cache for the engine.</p>
</div></details><h2 id="modules" class="section-header">Modules<a href="#modules" class="anchor">§</a></h2><dl class="item-table"><dt><a class="mod" href="cache_size/index.html" title="mod mito2::cache::cache_size">cache_<wbr>size</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Cache size of different cache value.</dd><dt><a class="mod" href="file_cache/index.html" title="mod mito2::cache::file_cache">file_<wbr>cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>A cache for files.</dd><dt><a class="mod" href="index/index.html" title="mod mito2::cache::index">index</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="mod" href="manifest_cache/index.html" title="mod mito2::cache::manifest_cache">manifest_<wbr>cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>A cache for manifest files.</dd><dt><a class="mod" href="write_cache/index.html" title="mod mito2::cache::write_cache">write_<wbr>cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>A write-through cache for remote object stores.</dd></dl><h2 id="structs" class="section-header">Structs<a href="#structs" class="anchor">§</a></h2><dl class="item-table"><dt><a class="struct" href="struct.CacheManager.html" title="struct mito2::cache::CacheManager">Cache<wbr>Manager</a></dt><dd>Manages cached data for the engine.</dd><dt><a class="struct" href="struct.CacheManagerBuilder.html" title="struct mito2::cache::CacheManagerBuilder">Cache<wbr>Manager<wbr>Builder</a></dt><dd>Builder to construct a <a href="struct.CacheManager.html" title="struct mito2::cache::CacheManager">CacheManager</a>.</dd><dt><a class="struct" href="struct.CachedSstMeta.html" title="struct mito2::cache::CachedSstMeta">Cached<wbr>SstMeta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Cached SST metadata combines the parquet footer with the decoded region metadata.</dd><dt><a class="struct" href="struct.CompactSstMeta.html" title="struct mito2::cache::CompactSstMeta">Compact<wbr>SstMeta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Compact, authoritative form of one SST’s metadata.</dd><dt><a class="struct" href="struct.PageFragmentGroupKey.html" title="struct mito2::cache::PageFragmentGroupKey">Page<wbr>Fragment<wbr>Group<wbr>Key</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="struct" href="struct.PageFragmentKey.html" title="struct mito2::cache::PageFragmentKey">Page<wbr>Fragment<wbr>Key</a></dt><dd>Cache key for one byte fragment in an SST row group.</dd><dt><a class="struct" href="struct.PageRangeCache.html" title="struct mito2::cache::PageRangeCache">Page<wbr>Range<wbr>Cache</a></dt><dd>Byte-fragment cache for Parquet row-group reads.</dd><dt><a class="struct" href="struct.PageRangeLookup.html" title="struct mito2::cache::PageRangeLookup">Page<wbr>Range<wbr>Lookup</a></dt><dd>Result of looking up request ranges in the page range cache.</dd><dt><a class="struct" href="struct.PageRangePart.html" title="struct mito2::cache::PageRangePart">Page<wbr>Range<wbr>Part</a></dt><dd>One cached byte fragment that overlaps a requested range.</dd><dt><a class="struct" href="struct.PrefilterKey.html" title="struct mito2::cache::PrefilterKey">Prefilter<wbr>Key</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Key for a cached prefilter result.</dd><dt><a class="struct" href="struct.PrefilterRowSelector.html" title="struct mito2::cache::PrefilterRowSelector">Prefilter<wbr>RowSelector</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="struct" href="struct.PreparedSstMeta.html" title="struct mito2::cache::PreparedSstMeta">Prepared<wbr>SstMeta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Both forms produced by decoding metadata after a cache miss.</dd><dt><a class="struct" href="struct.RangeResultMemoryLimiter.html" title="struct mito2::cache::RangeResultMemoryLimiter">Range<wbr>Result<wbr>Memory<wbr>Limiter</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="struct" href="struct.SelectorResultKey.html" title="struct mito2::cache::SelectorResultKey">Selector<wbr>Result<wbr>Key</a></dt><dd>Cache key for time series row selector result.</dd><dt><a class="struct" href="struct.SelectorResultValue.html" title="struct mito2::cache::SelectorResultValue">Selector<wbr>Result<wbr>Value</a></dt><dd>Cached result for time series row selector.</dd><dt><a class="struct" href="struct.SstMetaKey.html" title="struct mito2::cache::SstMetaKey">SstMeta<wbr>Key</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Cache key (region id, file id) for SST meta.</dd></dl><h2 id="enums" class="section-header">Enums<a href="#enums" class="anchor">§</a></h2><dl class="item-table"><dt><a class="enum" href="enum.CacheStrategy.html" title="enum mito2::cache::CacheStrategy">Cache<wbr>Strategy</a></dt><dd>Cache strategies that may only enable a subset of caches.</dd><dt><a class="enum" href="enum.SelectorResult.html" title="enum mito2::cache::SelectorResult">Selector<wbr>Result</a></dt><dd>Result stored in the selector result cache.</dd><dt><a class="enum" href="enum.SstMetaPreparation.html" title="enum mito2::cache::SstMetaPreparation">SstMeta<wbr>Preparation</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Result of decoding SST metadata and attempting to encode its compact cache entry.</dd></dl><h2 id="constants" class="section-header">Constants<a href="#constants" class="anchor">§</a></h2><dl class="item-table"><dt><a class="constant" href="constant.FILE_TYPE.html" title="constant mito2::cache::FILE_TYPE">FILE_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for files on the local store.</dd><dt><a class="constant" href="constant.INDEX_TYPE.html" title="constant mito2::cache::INDEX_TYPE">INDEX_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for index files (puffin) on the local store.</dd><dt><a class="constant" href="constant.PAGE_TYPE.html" title="constant mito2::cache::PAGE_TYPE">PAGE_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for pages.</dd><dt><a class="constant" href="constant.PREFILTER_RESULT_TYPE.html" title="constant mito2::cache::PREFILTER_RESULT_TYPE">PREFILTER_<wbr>RESULT_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for prefilter result cache.</dd><dt><a class="constant" href="constant.RANGE_RESULT_CONCAT_MEMORY_LIMIT.html" title="constant mito2::cache::RANGE_RESULT_CONCAT_MEMORY_LIMIT">RANGE_<wbr>RESULT_<wbr>CONCAT_<wbr>MEMORY_<wbr>LIMIT</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="constant" href="constant.RANGE_RESULT_CONCAT_MEMORY_PERMIT.html" title="constant mito2::cache::RANGE_RESULT_CONCAT_MEMORY_PERMIT">RANGE_<wbr>RESULT_<wbr>CONCAT_<wbr>MEMORY_<wbr>PERMIT</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="constant" href="constant.RANGE_RESULT_TYPE.html" title="constant mito2::cache::RANGE_RESULT_TYPE">RANGE_<wbr>RESULT_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for range scan result cache.</dd><dt><a class="constant" href="constant.SELECTOR_RESULT_TYPE.html" title="constant mito2::cache::SELECTOR_RESULT_TYPE">SELECTOR_<wbr>RESULT_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for selector result cache.</dd><dt><a class="constant" href="constant.SST_META_DECODED_TYPE.html" title="constant mito2::cache::SST_META_DECODED_TYPE">SST_<wbr>META_<wbr>DECODED_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for the optional decoded SST metadata acceleration tier.</dd><dt><a class="constant" href="constant.SST_META_TYPE.html" title="constant mito2::cache::SST_META_TYPE">SST_<wbr>META_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for sst meta.</dd><dt><a class="constant" href="constant.VECTOR_TYPE.html" title="constant mito2::cache::VECTOR_TYPE">VECTOR_<wbr>TYPE</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Metrics type key for vector.</dd></dl><h2 id="traits" class="section-header">Traits<a href="#traits" class="anchor">§</a></h2><dl class="item-table"><dt><a class="trait" href="trait.WriteCacheUploadStoreWrapper.html" title="trait mito2::cache::WriteCacheUploadStoreWrapper">Write<wbr>Cache<wbr>Upload<wbr>Store<wbr>Wrapper</a></dt><dd>Wraps the remote object store used by write cache uploads.</dd></dl><h2 id="functions" class="section-header">Functions<a href="#functions" class="anchor">§</a></h2><dl class="item-table"><dt><a class="fn" href="fn.decode_sst_meta.html" title="fn mito2::cache::decode_sst_meta">decode_<wbr>sst_<wbr>meta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Decodes SST metadata on the given blocking runtime without preparing a compact cache entry.</dd><dt><a class="fn" href="fn.decoded_meta_cache_weight.html" title="fn mito2::cache::decoded_meta_cache_weight">decoded_<wbr>meta_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.encode_compact_sst_meta.html" title="fn mito2::cache::encode_compact_sst_meta">encode_<wbr>compact_<wbr>sst_<wbr>meta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.finish_sst_meta_preparation.html" title="fn mito2::cache::finish_sst_meta_preparation">finish_<wbr>sst_<wbr>meta_<wbr>preparation</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.infer_loaded_page_index_policy.html" title="fn mito2::cache::infer_loaded_page_index_policy">infer_<wbr>loaded_<wbr>page_<wbr>index_<wbr>policy</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.meta_cache_weight.html" title="fn mito2::cache::meta_cache_weight">meta_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.new_prefilter_result_cache.html" title="fn mito2::cache::new_prefilter_result_cache">new_<wbr>prefilter_<wbr>result_<wbr>cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.page_cache_weight.html" title="fn mito2::cache::page_cache_weight">page_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.prefilter_result_cache_weight.html" title="fn mito2::cache::prefilter_result_cache_weight">prefilter_<wbr>result_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.prepare_sst_meta.html" title="fn mito2::cache::prepare_sst_meta">prepare_<wbr>sst_<wbr>meta</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Decodes SST metadata and attempts to encode both cache representations on the given blocking runtime.</dd><dt><a class="fn" href="fn.prepare_sst_meta_sync.html" title="fn mito2::cache::prepare_sst_meta_sync">prepare_<wbr>sst_<wbr>meta_<wbr>sync</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Synchronously prepares SST metadata. Callers must run this on a blocking runtime.</dd><dt><a class="fn" href="fn.range_result_cache_weight.html" title="fn mito2::cache::range_result_cache_weight">range_<wbr>result_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.removal_cause_str.html" title="fn mito2::cache::removal_cause_str">removal_<wbr>cause_<wbr>str</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.satisfies_page_index_policy.html" title="fn mito2::cache::satisfies_page_index_policy">satisfies_<wbr>page_<wbr>index_<wbr>policy</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.selector_result_cache_hit.html" title="fn mito2::cache::selector_result_cache_hit">selector_<wbr>result_<wbr>cache_<wbr>hit</a></dt><dd>Increases selector cache hit metrics.</dd><dt><a class="fn" href="fn.selector_result_cache_miss.html" title="fn mito2::cache::selector_result_cache_miss">selector_<wbr>result_<wbr>cache_<wbr>miss</a></dt><dd>Increases selector cache miss metrics.</dd><dt><a class="fn" href="fn.selector_result_cache_weight.html" title="fn mito2::cache::selector_result_cache_weight">selector_<wbr>result_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.strip_column_indexes.html" title="fn mito2::cache::strip_column_indexes">strip_<wbr>column_<wbr>indexes</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.strip_region_metadata_from_parquet.html" title="fn mito2::cache::strip_region_metadata_from_parquet">strip_<wbr>region_<wbr>metadata_<wbr>from_<wbr>parquet</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="fn" href="fn.update_hit_miss.html" title="fn mito2::cache::update_hit_miss">update_<wbr>hit_<wbr>miss</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Updates cache hit/miss metrics.</dd><dt><a class="fn" href="fn.vector_cache_weight.html" title="fn mito2::cache::vector_cache_weight">vector_<wbr>cache_<wbr>weight</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt></dl><h2 id="types" class="section-header">Type Aliases<a href="#types" class="anchor">§</a></h2><dl class="item-table"><dt><a class="type" href="type.CacheManagerRef.html" title="type mito2::cache::CacheManagerRef">Cache<wbr>Manager<wbr>Ref</a></dt><dt><a class="type" href="type.PageFragmentIndex.html" title="type mito2::cache::PageFragmentIndex">Page<wbr>Fragment<wbr>Index</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="type" href="type.PageFragmentRangeIndex.html" title="type mito2::cache::PageFragmentRangeIndex">Page<wbr>Fragment<wbr>Range<wbr>Index</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="type" href="type.PrefilterResultCache.html" title="type mito2::cache::PrefilterResultCache">Prefilter<wbr>Result<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="type" href="type.RangeResultCache.html" title="type mito2::cache::RangeResultCache">Range<wbr>Result<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Maps partition-range scan key to cached flat batches.</dd><dt><a class="type" href="type.SelectorResultCache.html" title="type mito2::cache::SelectorResultCache">Selector<wbr>Result<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Maps (file id, row group id, time series row selector) to <a href="struct.SelectorResultValue.html" title="struct mito2::cache::SelectorResultValue">SelectorResultValue</a>.</dd><dt><a class="type" href="type.SstDecodedMetaCache.html" title="type mito2::cache::SstDecodedMetaCache">SstDecoded<wbr>Meta<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Maps (region id, file id) to decoded SST metadata retained as an acceleration tier.</dd><dt><a class="type" href="type.SstMetaCache.html" title="type mito2::cache::SstMetaCache">SstMeta<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Maps (region id, file id) to fused SST metadata.</dd><dt><a class="type" href="type.VectorCache.html" title="type mito2::cache::VectorCache">Vector<wbr>Cache</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Maps [Value] to a vector that holds this value repeatedly.</dd><dt><a class="type" href="type.WriteCacheUploadStoreWrapperRef.html" title="type mito2::cache::WriteCacheUploadStoreWrapperRef">Write<wbr>Cache<wbr>Upload<wbr>Store<wbr>Wrapper<wbr>Ref</a></dt></dl></section></div></main></body></html>