mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-12-03 16:05:28 +00:00
27 lines
17 KiB
HTML
27 lines
17 KiB
HTML
<!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="Streaming boundary between finite raw-series chunks and DataFusion record batches."><title>common_query::series_frame - 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="common_query" 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 series_frame</a></h2></rustdoc-topbar><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../common_query/index.html">common_<wbr>query</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 series_<wbr>frame</a></h2><h3><a href="#structs">Module Items</a></h3><ul class="block"><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="#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 common_<wbr>query</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">common_query</a></div><h1>Module <span>series_<wbr>frame</span> <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/common_query/series_frame.rs.html#15-1682">Source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Streaming boundary between finite raw-series chunks and DataFusion record batches.</p>
|
||
<p>Schema fields identify the ordered logical payload fields and codec layout; additional
|
||
application metadata is permitted when stable across the stream. A key-encoded frame also
|
||
declares its own label decode description, and the frame is the sole source of decode
|
||
information: <a href="fn.unpack_raw_series.html" title="fn common_query::series_frame::unpack_raw_series"><code>unpack_raw_series</code></a> reads the fields, the label mode, the description, and the
|
||
producer ordering from the received schema, keeps the description on the returned stream, and
|
||
therefore needs no [<code>RawLabelSource</code>]. A caller that holds a scan-bound identity — the physical
|
||
region key layout a decoded identity came from — compares that identity’s declared label
|
||
decode layout with <a href="fn.ensure_frame_matches_label_source.html" title="fn common_query::series_frame::ensure_frame_matches_label_source"><code>ensure_frame_matches_label_source</code></a> instead of passing it as a decode
|
||
input; that comparison is equality of the description alone and proves nothing about region
|
||
identity or provenance, and neither side is authenticated as field provenance. This adapter
|
||
preserves
|
||
scan candidates only; it is not a residual filter, authorization check, remote transport, or
|
||
compaction boundary. Raw frames accept all three [<code>SeriesOrdering</code>] declarations, while evaluated
|
||
frames accept only <code>Contiguous</code>. Raw <code>Interleaved</code> supports independently closed producer
|
||
fragment chains in sequence, including recurring keys; it does not multiplex open chains.</p>
|
||
<p>An evaluated frame is the same physical family: <a href="fn.pack_evaluated_series.html" title="fn common_query::series_frame::pack_evaluated_series"><code>pack_evaluated_series</code></a> and
|
||
<a href="fn.unpack_evaluated_series.html" title="fn common_query::series_frame::unpack_evaluated_series"><code>unpack_evaluated_series</code></a> carry computed values under complete labels and grid positions, so a
|
||
compute consumer needs neither a storage key nor a scan binding to read them.</p>
|
||
</div></details><h2 id="structs" class="section-header">Structs<a href="#structs" class="anchor">§</a></h2><dl class="item-table"><dt><a class="struct" href="struct.EvaluatedSequenceValidator.html" title="struct common_query::series_frame::EvaluatedSequenceValidator">Evaluated<wbr>Sequence<wbr>Validator</a></dt><dd>Cross-chunk validation state for evaluated chains.</dd><dt><a class="struct" href="struct.PackBatches.html" title="struct common_query::series_frame::PackBatches">Pack<wbr>Batches</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The batching half of a pack stream: the builder, the cursor installed in it, and the declared
|
||
schema every ready batch is published under.</dd><dt><a class="struct" href="struct.PackEvaluatedStream.html" title="struct common_query::series_frame::PackEvaluatedStream">Pack<wbr>Evaluated<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The pack stream of <a href="fn.pack_evaluated_series.html" title="fn common_query::series_frame::pack_evaluated_series"><code>pack_evaluated_series</code></a>.</dd><dt><a class="struct" href="struct.PackStateStream.html" title="struct common_query::series_frame::PackStateStream">Pack<wbr>State<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The pack stream of <a href="fn.pack_aggregate_state.html" title="fn common_query::series_frame::pack_aggregate_state"><code>pack_aggregate_state</code></a>.</dd><dt><a class="struct" href="struct.PackStream.html" title="struct common_query::series_frame::PackStream">Pack<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="struct" href="struct.PendingFlush.html" title="struct common_query::series_frame::PendingFlush">Pending<wbr>Flush</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Bounded batching across a pending raw source.</dd><dt><a class="struct" href="struct.SequenceValidator.html" title="struct common_query::series_frame::SequenceValidator">Sequence<wbr>Validator</a></dt><dd>Cross-chunk validation state for raw producer fragment chains. Every chain’s chunks must be
|
||
contiguous, including for <code>Interleaved</code>; this validator checks adjacent chunks only and retains
|
||
the previous owned key (not an Arrow buffer), timestamp, metric, and finality. An <code>Interleaved</code>
|
||
chain releases that state on closure, so later fragment chains may recur with the same key,
|
||
labels, and timestamps independently.</dd><dt><a class="struct" href="struct.UnpackEvaluatedStream.html" title="struct common_query::series_frame::UnpackEvaluatedStream">Unpack<wbr>Evaluated<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The unpack stream of <a href="fn.unpack_evaluated_series.html" title="fn common_query::series_frame::unpack_evaluated_series"><code>unpack_evaluated_series</code></a>.</dd><dt><a class="struct" href="struct.UnpackStateStream.html" title="struct common_query::series_frame::UnpackStateStream">Unpack<wbr>State<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The unpack stream of <a href="fn.unpack_aggregate_state.html" title="fn common_query::series_frame::unpack_aggregate_state"><code>unpack_aggregate_state</code></a>.</dd><dt><a class="struct" href="struct.UnpackStream.html" title="struct common_query::series_frame::UnpackStream">Unpack<wbr>Stream</a><span title="Restricted Visibility"> 🔒</span> </dt></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.PendingBatching.html" title="enum common_query::series_frame::PendingBatching">Pending<wbr>Batching</a></dt><dd>How a pack stream treats the rows it has buffered when its source reports <code>Pending</code>.</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.MAX_EMPTY_BATCHES_PER_POLL.html" title="constant common_query::series_frame::MAX_EMPTY_BATCHES_PER_POLL">MAX_<wbr>EMPTY_<wbr>BATCHES_<wbr>PER_<wbr>POLL</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>How many empty batches one poll reads before yielding, so a stream of them cannot hold the task.</dd><dt><a class="constant" href="constant.ORDERING_KEY.html" title="constant common_query::series_frame::ORDERING_KEY">ORDERING_<wbr>KEY</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="constant" href="constant.PENDING_FLUSH_DELAY.html" title="constant common_query::series_frame::PENDING_FLUSH_DELAY">PENDING_<wbr>FLUSH_<wbr>DELAY</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>How long a pending source may keep buffered rows before they are published as a batch of their
|
||
own.</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.codec_error.html" title="fn common_query::series_frame::codec_error">codec_<wbr>error</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.current_runtime_id.html" title="fn common_query::series_frame::current_runtime_id">current_<wbr>runtime_<wbr>id</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>The runtime that would own a timer armed by the current poll, if there is one.</dd><dt><a class="fn" href="fn.declared_label_mode.html" title="fn common_query::series_frame::declared_label_mode">declared_<wbr>label_<wbr>mode</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Returns the label mode a frame declares: a key frame describes its key, an explicit frame
|
||
carries complete labels and declares no description.</dd><dt><a class="fn" href="fn.ensure_contiguous_ordering.html" title="fn common_query::series_frame::ensure_contiguous_ordering">ensure_<wbr>contiguous_<wbr>ordering</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Rejects an evaluated frame that claims more order than its producer promised.</dd><dt><a class="fn" href="fn.ensure_declared_schema.html" title="fn common_query::series_frame::ensure_declared_schema">ensure_<wbr>declared_<wbr>schema</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Rejects an <code>expected</code> series schema the frame does not declare.</dd><dt><a class="fn" href="fn.ensure_frame_matches_label_source.html" title="fn common_query::series_frame::ensure_frame_matches_label_source">ensure_<wbr>frame_<wbr>matches_<wbr>label_<wbr>source</a></dt><dd>Checks that a frame declares the label decode layout a scan-bound binding describes.</dd><dt><a class="fn" href="fn.frame_schema_with.html" title="fn common_query::series_frame::frame_schema_with">frame_<wbr>schema_<wbr>with</a></dt><dd>Assembles a declared frame schema from an explicit label mode and decode description.</dd><dt><a class="fn" href="fn.invalid.html" title="fn common_query::series_frame::invalid">invalid</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.label_decode_spec.html" title="fn common_query::series_frame::label_decode_spec">label_<wbr>decode_<wbr>spec</a></dt><dd>Derives the label decode description a frame must carry for this binding.</dd><dt><a class="fn" href="fn.label_mode.html" title="fn common_query::series_frame::label_mode">label_<wbr>mode</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.pack_aggregate_state.html" title="fn common_query::series_frame::pack_aggregate_state">pack_<wbr>aggregate_<wbr>state</a></dt><dd>Packs aggregate-state chunks into bounded DataFusion record batches.</dd><dt><a class="fn" href="fn.pack_evaluated_series.html" title="fn common_query::series_frame::pack_evaluated_series">pack_<wbr>evaluated_<wbr>series</a></dt><dd>Packs a stream of evaluated chunks into DataFusion record batches incrementally.</dd><dt><a class="fn" href="fn.pack_raw_series.html" title="fn common_query::series_frame::pack_raw_series">pack_<wbr>raw_<wbr>series</a></dt><dd>Packs a storage raw-series stream into DataFusion record batches incrementally.</dd><dt><a class="fn" href="fn.pack_raw_series_with.html" title="fn common_query::series_frame::pack_raw_series_with">pack_<wbr>raw_<wbr>series_<wbr>with</a></dt><dd>Packs a storage raw-series stream with the pending batching its poller can support.</dd><dt><a class="fn" href="fn.raw_series_frame_schema_with_ordering.html" title="fn common_query::series_frame::raw_series_frame_schema_with_ordering">raw_<wbr>series_<wbr>frame_<wbr>schema_<wbr>with_<wbr>ordering</a></dt><dd>Builds the canonical raw frame schema with the producer’s label binding and ordering.</dd><dt><a class="fn" href="fn.series_frame_ordering.html" title="fn common_query::series_frame::series_frame_ordering">series_<wbr>frame_<wbr>ordering</a></dt><dd>Reads the producer ordering declared by a complete v2 frame schema.</dd><dt><a class="fn" href="fn.unpack_aggregate_state.html" title="fn common_query::series_frame::unpack_aggregate_state">unpack_<wbr>aggregate_<wbr>state</a></dt><dd>Unpacks aggregate-state frames while retaining Arrow-backed state rows.</dd><dt><a class="fn" href="fn.unpack_error.html" title="fn common_query::series_frame::unpack_error">unpack_<wbr>error</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Wraps a decode or validation error as the boxed error an unpack stream reports.</dd><dt><a class="fn" href="fn.unpack_evaluated_series.html" title="fn common_query::series_frame::unpack_evaluated_series">unpack_<wbr>evaluated_<wbr>series</a></dt><dd>Unpacks DataFusion batches declared by <a href="fn.pack_evaluated_series.html" title="fn common_query::series_frame::pack_evaluated_series"><code>pack_evaluated_series</code></a>.</dd><dt><a class="fn" href="fn.unpack_raw_series.html" title="fn common_query::series_frame::unpack_raw_series">unpack_<wbr>raw_<wbr>series</a></dt><dd>Unpacks DataFusion batches declared by <a href="fn.pack_raw_series.html" title="fn common_query::series_frame::pack_raw_series"><code>pack_raw_series</code></a>.</dd><dt><a class="fn" href="fn.upstream_error.html" title="fn common_query::series_frame::upstream_error">upstream_<wbr>error</a><span title="Restricted Visibility"> 🔒</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.SendableEvaluatedSeriesStream.html" title="type common_query::series_frame::SendableEvaluatedSeriesStream">Sendable<wbr>Evaluated<wbr>Series<wbr>Stream</a></dt><dd>A stream of evaluated series chunks and their finality.</dd><dt><a class="type" href="type.SendableStateFrameStream.html" title="type common_query::series_frame::SendableStateFrameStream">Sendable<wbr>State<wbr>Frame<wbr>Stream</a></dt><dd>A stream of decoded state rows retaining typed handles into their Arrow batch.</dd><dt><a class="type" href="type.SendableStateSeriesStream.html" title="type common_query::series_frame::SendableStateSeriesStream">Sendable<wbr>State<wbr>Series<wbr>Stream</a></dt><dd>A stream of aggregate-state chunks and their producer-local finality.</dd></dl></section></div></main></body></html> |