Skip to content
This repository has been archived by the owner on Sep 18, 2023. It is now read-only.

[NSE-42] early release sort input #43

Merged
merged 2 commits into from
Jan 18, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ class ColumnarSorter(
elapse.set(NANOSECONDS.toMillis(total_elapse))
sortTime.set(NANOSECONDS.toMillis(sort_elapse))
shuffleTime.set(NANOSECONDS.toMillis(shuffle_elapse))
inputBatchHolder.foreach(cb => cb.close())
if (sorter != null) {
sorter.close()
}
Expand Down Expand Up @@ -153,7 +152,12 @@ class ColumnarSorter(
sort_elapse += System.nanoTime() - beforeSort
total_elapse += System.nanoTime() - beforeSort
}
sort_iterator.hasNext()
if (sort_iterator.hasNext()) {
return true
} else {
inputBatchHolder.foreach(cb => cb.close())
return false
}
}

override def next(): ColumnarBatch = {
Expand Down