mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
Tiny fix.
This commit is contained in:
parent
24dac111b7
commit
9d3e8fb9c3
@ -642,19 +642,21 @@ bool StorageKafka::streamToViews()
|
||||
// It will be cancelled on underlying layer (kafka buffer)
|
||||
|
||||
size_t rows = 0;
|
||||
PushingPipelineExecutor executor(block_io.pipeline);
|
||||
|
||||
in->readPrefix();
|
||||
executor.start();
|
||||
|
||||
while (auto block = in->read())
|
||||
{
|
||||
rows += block.rows();
|
||||
executor.push(std::move(block));
|
||||
}
|
||||
PushingPipelineExecutor executor(block_io.pipeline);
|
||||
|
||||
in->readSuffix();
|
||||
executor.finish();
|
||||
in->readPrefix();
|
||||
executor.start();
|
||||
|
||||
while (auto block = in->read())
|
||||
{
|
||||
rows += block.rows();
|
||||
executor.push(std::move(block));
|
||||
}
|
||||
|
||||
in->readSuffix();
|
||||
executor.finish();
|
||||
}
|
||||
|
||||
bool some_stream_is_stalled = false;
|
||||
for (auto & stream : streams)
|
||||
|
@ -997,13 +997,15 @@ bool StorageRabbitMQ::streamToViews()
|
||||
looping_task->activateAndSchedule();
|
||||
}
|
||||
|
||||
PushingPipelineExecutor executor(block_io.pipeline);
|
||||
executor.start();
|
||||
in->readPrefix();
|
||||
while (auto block = in->read())
|
||||
executor.push(std::move(block));
|
||||
executor.finish();
|
||||
in->readSuffix();
|
||||
{
|
||||
PushingPipelineExecutor executor(block_io.pipeline);
|
||||
in->readPrefix();
|
||||
executor.start();
|
||||
while (auto block = in->read())
|
||||
executor.push(std::move(block));
|
||||
in->readSuffix();
|
||||
executor.finish();
|
||||
}
|
||||
|
||||
/* Note: sending ack() with loop running in another thread will lead to a lot of data races inside the library, but only in case
|
||||
* error occurs or connection is lost while ack is being sent
|
||||
|
Loading…
Reference in New Issue
Block a user