Skip to content

Commit c4c2ff1

Browse files
committed
Disable prefetching strictly
1 parent f3f4cda commit c4c2ff1

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎datafusion/physical-plan/src/joins/grace_hash_join/exec.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1039,7 +1039,7 @@ async fn partition_and_spill_one_side(
10391039
const MAX_TOTAL_TARGET_BUFFER_BYTES: usize = 256 * 1024 * 1024;
10401040
const MIN_FLUSH_BYTES: usize = 1 * 1024 * 1024;
10411041
const MAX_FLUSH_BYTES: usize = 32 * 1024 * 1024;
1042-
const MAX_SPILL_FILES_PER_SIDE: usize = 128;
1042+
const MAX_SPILL_FILES_PER_SIDE: usize = 1024;
10431043

10441044
let total_target_buffer = partition_write_buffer_bytes
10451045
.clamp(MIN_TOTAL_TARGET_BUFFER_BYTES, MAX_TOTAL_TARGET_BUFFER_BYTES);

‎datafusion/physical-plan/src/joins/grace_hash_join/stream.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1084,7 +1084,7 @@ impl GraceHashJoinStream {
10841084
.adaptive_budget
10851085
.current_limit()
10861086
.min(PREFETCH_MAX_BYTES);
1087-
if estimated_size <= cap {
1087+
if PREFETCH_MAX_BYTES > 0 && estimated_size <= cap {
10881088
let left_bytes_pf = Arc::new(Mutex::new(0usize));
10891089
let right_bytes_pf = Arc::new(Mutex::new(0usize));
10901090
let left_fut_pf = load_partition_async(

0 commit comments

Comments
 (0)