mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-22 23:52:03 +00:00
Merge pull request #45481 from ClickHouse/fix-deadlock-with-allow_asynchronous_read_from_io_pool_for_merge_tree
Fix possible deadlock with allow_asynchronous_read_from_io_pool_for_merge_tree in case of exception from ThreadPool::schedule
This commit is contained in:
commit
b877c484d2
@ -104,7 +104,16 @@ struct MergeTreeSource::AsyncReadingState
|
||||
|
||||
void schedule(ThreadPool::Job job)
|
||||
{
|
||||
callback_runner(std::move(job), 0);
|
||||
try
|
||||
{
|
||||
callback_runner(std::move(job), 0);
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
/// Roll back stage in case of exception from ThreadPool::schedule
|
||||
control->stage = Stage::NotStarted;
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
ChunkAndProgress getResult()
|
||||
|
Loading…
Reference in New Issue
Block a user