mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 00:22:29 +00:00
cancel workers when exception
This commit is contained in:
parent
08dc874a37
commit
e2bfa83429
@ -166,6 +166,8 @@ private:
|
||||
|
||||
std::vector<std::future<void>> futures;
|
||||
SCOPE_EXIT_SAFE({
|
||||
/// Cancel all workers
|
||||
worker_state.next_task.store(worker_state.tasks.size());
|
||||
/// Exceptions are not propagated
|
||||
for (auto & future : futures)
|
||||
if (future.valid())
|
||||
|
Loading…
Reference in New Issue
Block a user