Skip to content

Commit ea64d05

Browse files
committed
fix
1 parent 17f9519 commit ea64d05

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/query/service/src/pipelines/processors/transforms/transform_partition_collect.rs

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,6 @@ pub struct TransformHilbertPartitionCollect {
9494
restored_data_blocks: Vec<DataBlock>,
9595
output_data_blocks: Vec<DataBlock>,
9696

97-
max_block_size: usize,
9897
// The partition id is used to map the partition id to the new partition id.
9998
partition_id: Vec<usize>,
10099
// The buffer is used to control the memory usage of the window operator.
@@ -150,7 +149,6 @@ impl TransformHilbertPartitionCollect {
150149
buffer,
151150
output_data_blocks: vec![],
152151
restored_data_blocks: Vec::new(),
153-
max_block_size,
154152
state: State::Consume,
155153
})
156154
}
@@ -201,16 +199,16 @@ impl Processor for TransformHilbertPartitionCollect {
201199
return Ok(Event::NeedConsume);
202200
}
203201

204-
if let Some(data_block) = self.output_data_blocks.pop() {
205-
self.output.push_data(Ok(data_block));
206-
return Ok(Event::NeedConsume);
207-
}
208-
209202
if self.need_spill() {
210203
self.state = State::Spill;
211204
return Ok(Event::Async);
212205
}
213206

207+
if let Some(data_block) = self.output_data_blocks.pop() {
208+
self.output.push_data(Ok(data_block));
209+
return Ok(Event::NeedConsume);
210+
}
211+
214212
if self.input.is_finished() {
215213
if !self.buffer.is_empty() {
216214
self.state = State::Restore;

0 commit comments

Comments
 (0)