Module window_sort

Source
Expand description

A physical plan for window sort(Which is sorting multiple sorted ranges according to input PartitionRange).

Structsยง

SortedRunSet ๐Ÿ”’
SucRun ๐Ÿ”’
A struct to represent a successive run in the input iterator
TimeRange ๐Ÿ”’
Left(start) inclusive right(end) exclusive,
WindowedSortExec
A complex stream sort execution plan which accepts a list of PartitionRange 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.
WindowedSortStream
The core logic of merging sort multiple sorted ranges

Enumsยง

Action ๐Ÿ”’

Functionsยง

check_partition_range_monotonicity ๐Ÿ”’
cmp_with_opts ๐Ÿ”’
Compare with options, note None is considered as NULL here
compute_all_working_ranges ๐Ÿ”’
Compute all working ranges and corresponding working sets from given overlap_counts computed from split_overlapping_ranges
find_slice_from_range ๐Ÿ”’
Find the slice(where start <= data < end and sort by sort_column.options) from the given range
find_successive_runs ๐Ÿ”’
find all successive runs in the input iterator
get_sorted_runs ๐Ÿ”’
return a list of non-overlapping (offset, length) which represent sorted runs, and can be used to call [DfRecordBatch::slice] to get sorted runs Returned runs will be as long as possible, and will not overlap with each other
get_timestamp_from_idx ๐Ÿ”’
Get timestamp from array at offset
split_batch_to_sorted_run ๐Ÿ”’
split batch to sorted runs
split_overlapping_ranges ๐Ÿ”’
return a map of non-overlapping ranges and their corresponding index (not PartitionRange.identifier but position in array) in the input PartitionRanges that is in those ranges
split_range_by ๐Ÿ”’
split input range by split_by range to one, two or three parts.