mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-17 13:13:36 +00:00
Fix
This commit is contained in:
parent
f17d1bc7a5
commit
fbd2f40b05
@ -571,6 +571,7 @@ ASTs InterpreterAlterImpl::getRewrittenQueries(
|
|||||||
auto rewritten_rename_query = std::make_shared<ASTRenameQuery>();
|
auto rewritten_rename_query = std::make_shared<ASTRenameQuery>();
|
||||||
rewritten_alter_query->database = mapped_to_database;
|
rewritten_alter_query->database = mapped_to_database;
|
||||||
rewritten_alter_query->table = alter_query.table;
|
rewritten_alter_query->table = alter_query.table;
|
||||||
|
rewritten_alter_query->alter_object = ASTAlterQuery::AlterObjectType::TABLE;
|
||||||
rewritten_alter_query->set(rewritten_alter_query->command_list, std::make_shared<ASTExpressionList>());
|
rewritten_alter_query->set(rewritten_alter_query->command_list, std::make_shared<ASTExpressionList>());
|
||||||
|
|
||||||
String default_after_column;
|
String default_after_column;
|
||||||
|
@ -456,7 +456,7 @@ void PostgreSQLReplicationHandler::setSetting(const SettingChange & setting)
|
|||||||
{
|
{
|
||||||
consumer_task->deactivate();
|
consumer_task->deactivate();
|
||||||
consumer->setSetting(setting);
|
consumer->setSetting(setting);
|
||||||
consumer_task->schedule();
|
consumer_task->activateAndSchedule();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -658,6 +658,7 @@ void PostgreSQLReplicationHandler::addTableToReplication(StorageMaterializedPost
|
|||||||
}
|
}
|
||||||
catch (...)
|
catch (...)
|
||||||
{
|
{
|
||||||
|
consumer_task->activate();
|
||||||
consumer_task->scheduleAfter(RESCHEDULE_MS);
|
consumer_task->scheduleAfter(RESCHEDULE_MS);
|
||||||
|
|
||||||
auto error_message = getCurrentExceptionMessage(false);
|
auto error_message = getCurrentExceptionMessage(false);
|
||||||
@ -685,13 +686,14 @@ void PostgreSQLReplicationHandler::removeTableFromReplication(const String & pos
|
|||||||
}
|
}
|
||||||
catch (...)
|
catch (...)
|
||||||
{
|
{
|
||||||
|
consumer_task->activate();
|
||||||
consumer_task->scheduleAfter(RESCHEDULE_MS);
|
consumer_task->scheduleAfter(RESCHEDULE_MS);
|
||||||
|
|
||||||
auto error_message = getCurrentExceptionMessage(false);
|
auto error_message = getCurrentExceptionMessage(false);
|
||||||
throw Exception(ErrorCodes::POSTGRESQL_REPLICATION_INTERNAL_ERROR,
|
throw Exception(ErrorCodes::POSTGRESQL_REPLICATION_INTERNAL_ERROR,
|
||||||
"Failed to remove table `{}` from replication. Info: {}", postgres_table_name, error_message);
|
"Failed to remove table `{}` from replication. Info: {}", postgres_table_name, error_message);
|
||||||
}
|
}
|
||||||
consumer_task->schedule();
|
consumer_task->activateAndSchedule();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user