Skip to content

Commit 4542e0b

Browse files
committed
streaming buffer fix
1 parent 93b8db1 commit 4542e0b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/distributed_execution/remote_node.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ func newDistributedRemoteExecution(ctx context.Context, pool *client.Pool, fragm
163163
batchSize: 1000,
164164
fragmentKey: fragmentKey,
165165
addr: childIDToAddr[fragmentKey.fragmentID],
166-
buffer: nil,
166+
buffer: []model.StepVector{},
167167
bufferIndex: 0,
168168
initialized: false,
169169
}
@@ -288,7 +288,7 @@ func (d *DistributedRemoteExecution) Next(ctx context.Context) ([]model.StepVect
288288
}
289289
}
290290

291-
end := int(d.batchSize)
291+
end := len(d.buffer)
292292
if end > len(d.buffer) {
293293
end = len(d.buffer)
294294
}

0 commit comments

Comments
 (0)