mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-23 10:10:50 +00:00
fix style check - clang format for lambdas
This commit is contained in:
parent
ea40e7b403
commit
1244ca5627
@ -116,7 +116,9 @@ void DatabaseOrdinary::loadStoredObjects(Context & context, bool has_force_resto
|
|||||||
|
|
||||||
size_t total_dictionaries = 0;
|
size_t total_dictionaries = 0;
|
||||||
|
|
||||||
auto process_metadata = [&context, &file_names, &total_dictionaries, this](const String & file_name) {
|
// clang-format off
|
||||||
|
auto process_metadata = [&context, &file_names, &total_dictionaries, this](const String & file_name)
|
||||||
|
{
|
||||||
fs::path path(getMetadataPath());
|
fs::path path(getMetadataPath());
|
||||||
fs::path file_path(file_name);
|
fs::path file_path(file_name);
|
||||||
fs::path full_path = path / file_path;
|
fs::path full_path = path / file_path;
|
||||||
@ -137,6 +139,8 @@ void DatabaseOrdinary::loadStoredObjects(Context & context, bool has_force_resto
|
|||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
// clang-format on
|
||||||
|
|
||||||
|
|
||||||
iterateMetadataFiles(context, process_metadata);
|
iterateMetadataFiles(context, process_metadata);
|
||||||
|
|
||||||
@ -155,7 +159,9 @@ void DatabaseOrdinary::loadStoredObjects(Context & context, bool has_force_resto
|
|||||||
{
|
{
|
||||||
const auto & create_query = name_with_query.second->as<const ASTCreateQuery &>();
|
const auto & create_query = name_with_query.second->as<const ASTCreateQuery &>();
|
||||||
if (!create_query.is_dictionary)
|
if (!create_query.is_dictionary)
|
||||||
pool.scheduleOrThrowOnError([&]() {
|
// clang-format off
|
||||||
|
pool.scheduleOrThrowOnError([&]()
|
||||||
|
{
|
||||||
tryAttachTable(
|
tryAttachTable(
|
||||||
context,
|
context,
|
||||||
create_query,
|
create_query,
|
||||||
@ -167,6 +173,7 @@ void DatabaseOrdinary::loadStoredObjects(Context & context, bool has_force_resto
|
|||||||
/// Messages, so that it's not boring to wait for the server to load for a long time.
|
/// Messages, so that it's not boring to wait for the server to load for a long time.
|
||||||
logAboutProgress(log, ++tables_processed, total_tables, watch);
|
logAboutProgress(log, ++tables_processed, total_tables, watch);
|
||||||
});
|
});
|
||||||
|
// clang-format on
|
||||||
}
|
}
|
||||||
|
|
||||||
pool.wait();
|
pool.wait();
|
||||||
@ -200,10 +207,14 @@ void DatabaseOrdinary::startupTables(ThreadPool & thread_pool)
|
|||||||
AtomicStopwatch watch;
|
AtomicStopwatch watch;
|
||||||
std::atomic<size_t> tables_processed{0};
|
std::atomic<size_t> tables_processed{0};
|
||||||
|
|
||||||
auto startup_one_table = [&](const StoragePtr & table) {
|
// clang-format off
|
||||||
|
auto startup_one_table = [&](const StoragePtr & table)
|
||||||
|
{
|
||||||
table->startup();
|
table->startup();
|
||||||
logAboutProgress(log, ++tables_processed, total_tables, watch);
|
logAboutProgress(log, ++tables_processed, total_tables, watch);
|
||||||
};
|
};
|
||||||
|
// clang-format on
|
||||||
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user