risingwave_frontend::scheduler::plan_fragmenter

Function derive_partitions

source
fn derive_partitions(
    scan_ranges: &[ScanRange],
    table_desc: &TableDesc,
    vnode_mapping: &WorkerSlotMapping,
) -> Result<HashMap<WorkerSlotId, TablePartitionInfo>, SchedulerError>
Expand description

Try to derive the partition to read from the scan range. It can be derived if the value of the distribution key is already known.