Files
greptimedb/query/window_sort/index.html
2025-12-22 06:16:12 +00:00

7 lines
8.2 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="A physical plan for window sort(Which is sorting multiple sorted ranges according to input `PartitionRange`)."><title>query::window_sort - 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-e56847b5.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="query" data-themes="" data-resource-suffix="" data-rustdoc-version="1.92.0-nightly (fa3155a64 2025-09-30)" data-channel="nightly" data-search-js="search-e256b49e.js" data-stringdex-js="stringdex-828709d0.js" data-settings-js="settings-c38705f0.js" ><script src="../../static.files/storage-e2aeef58.js"></script><script defer src="../sidebar-items.js"></script><script defer src="../../static.files/main-ce535bd0.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-263c88ec.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"><!--[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 window_sort</a></h2></rustdoc-topbar><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../query/index.html">query</a><span class="version">1.0.0-beta.3</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Module window_<wbr>sort</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="#functions" title="Functions">Functions</a></li></ul></section><div id="rustdoc-modnav"><h2 class="in-crate"><a href="../index.html">In crate 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"><div class="main-heading"><div class="rustdoc-breadcrumbs"><a href="../index.html">query</a></div><h1>Module <span>window_<wbr>sort</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/query/window_sort.rs.html#15-2956">Source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>A physical plan for window sort(Which is sorting multiple sorted ranges according to input <code>PartitionRange</code>).</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.SortedRunSet.html" title="struct query::window_sort::SortedRunSet">Sorted<wbr>RunSet</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dt><a class="struct" href="struct.SucRun.html" title="struct query::window_sort::SucRun">SucRun</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>A struct to represent a successive run in the input iterator</dd><dt><a class="struct" href="struct.TimeRange.html" title="struct query::window_sort::TimeRange">Time<wbr>Range</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Left(<code>start</code>) inclusive right(<code>end</code>) exclusive,</dd><dt><a class="struct" href="struct.WindowedSortExec.html" title="struct query::window_sort::WindowedSortExec">Windowed<wbr>Sort<wbr>Exec</a></dt><dd>A complex stream sort execution plan which accepts a list of <code>PartitionRange</code> and
merge sort them whenever possible, and emit the sorted result as soon as possible.
This sorting plan only accept sort by ts and will not sort by other fields.</dd><dt><a class="struct" href="struct.WindowedSortStream.html" title="struct query::window_sort::WindowedSortStream">Windowed<wbr>Sort<wbr>Stream</a></dt><dd>The core logic of merging sort multiple sorted ranges</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.Action.html" title="enum query::window_sort::Action">Action</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt></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.check_partition_range_monotonicity.html" title="fn query::window_sort::check_partition_range_monotonicity">check_<wbr>partition_<wbr>range_<wbr>monotonicity</a></dt><dd>Checks that partition ranges are sorted correctly for the given sort direction.</dd><dt><a class="fn" href="fn.cmp_with_opts.html" title="fn query::window_sort::cmp_with_opts">cmp_<wbr>with_<wbr>opts</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Compare with options, note None is considered as NULL here</dd><dt><a class="fn" href="fn.compute_all_working_ranges.html" title="fn query::window_sort::compute_all_working_ranges">compute_<wbr>all_<wbr>working_<wbr>ranges</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Compute all working ranges and corresponding working sets from given <code>overlap_counts</code> computed from <code>split_overlapping_ranges</code></dd><dt><a class="fn" href="fn.find_slice_from_range.html" title="fn query::window_sort::find_slice_from_range">find_<wbr>slice_<wbr>from_<wbr>range</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Find the slice(where start &lt;= data &lt; end and sort by <code>sort_column.options</code>) from the given range</dd><dt><a class="fn" href="fn.find_successive_runs.html" title="fn query::window_sort::find_successive_runs">find_<wbr>successive_<wbr>runs</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>find all successive runs in the input iterator</dd><dt><a class="fn" href="fn.get_sorted_runs.html" title="fn query::window_sort::get_sorted_runs">get_<wbr>sorted_<wbr>runs</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>return a list of non-overlapping (offset, length) which represent sorted runs, and
can be used to call [<code>DfRecordBatch::slice</code>] to get sorted runs
Returned runs will be as long as possible, and will not overlap with each other</dd><dt><a class="fn" href="fn.get_timestamp_from_idx.html" title="fn query::window_sort::get_timestamp_from_idx">get_<wbr>timestamp_<wbr>from_<wbr>idx</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>Get timestamp from array at offset</dd><dt><a class="fn" href="fn.split_batch_to_sorted_run.html" title="fn query::window_sort::split_batch_to_sorted_run">split_<wbr>batch_<wbr>to_<wbr>sorted_<wbr>run</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>split batch to sorted runs</dd><dt><a class="fn" href="fn.split_overlapping_ranges.html" title="fn query::window_sort::split_overlapping_ranges">split_<wbr>overlapping_<wbr>ranges</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>return a map of non-overlapping ranges and their corresponding index
(not <code>PartitionRange.identifier</code> but position in array) in the input <code>PartitionRange</code>s that is in those ranges</dd><dt><a class="fn" href="fn.split_range_by.html" title="fn query::window_sort::split_range_by">split_<wbr>range_<wbr>by</a><span title="Restricted Visibility">&nbsp;🔒</span> </dt><dd>split input range by <code>split_by</code> range to one, two or three parts.</dd></dl></section></div></main></body></html>