mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 16:12:01 +00:00
Prevent abort on shutdown if the fs is readonly
This commit is contained in:
parent
0eade98688
commit
b5c79201c3
@ -108,7 +108,18 @@ void StorageMergeTree::shutdown()
|
||||
if (shutdown_called)
|
||||
return;
|
||||
shutdown_called = true;
|
||||
clearOldPartsFromFilesystem(true);
|
||||
|
||||
try
|
||||
{
|
||||
clearOldPartsFromFilesystem(true);
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
/// Example: the case of readonly filesystem, we have failure removing old parts.
|
||||
/// Should not prevent table shutdown.
|
||||
tryLogCurrentException(log);
|
||||
}
|
||||
|
||||
merger_mutator.merges_blocker.cancelForever();
|
||||
parts_mover.moves_blocker.cancelForever();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user