mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-30 11:32:03 +00:00
Fix uncaught exception in background tasj
This commit is contained in:
parent
3cd175d11d
commit
4bc32c6387
@ -322,8 +322,19 @@ void DatabasePostgreSQL::loadStoredObjects(ContextMutablePtr /* context */, Load
|
||||
void DatabasePostgreSQL::removeOutdatedTables()
|
||||
{
|
||||
std::lock_guard lock{mutex};
|
||||
auto connection_holder = pool->get();
|
||||
auto actual_tables = fetchPostgreSQLTablesList(connection_holder->get(), configuration.schema);
|
||||
|
||||
std::set<std::string> actual_tables;
|
||||
try
|
||||
{
|
||||
auto connection_holder = pool->get();
|
||||
actual_tables = fetchPostgreSQLTablesList(connection_holder->get(), configuration.schema);
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
tryLogCurrentException(__PRETTY_FUNCTION__);
|
||||
cleaner_task->scheduleAfter(cleaner_reschedule_ms);
|
||||
return;
|
||||
}
|
||||
|
||||
if (cache_tables)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user