From 2b20eca06b23c96c2edb66784490bc8e585f4846 Mon Sep 17 00:00:00 2001 From: Alexey Milovidov Date: Tue, 23 May 2017 21:37:14 +0300 Subject: [PATCH] Preparations, part 4: StorageDistributed is initialized with const Context [#CLICKHOUSE-31]. --- dbms/src/Storages/StorageDistributed.cpp | 10 +++++----- dbms/src/Storages/StorageDistributed.h | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/dbms/src/Storages/StorageDistributed.cpp b/dbms/src/Storages/StorageDistributed.cpp index 42d315f14b..9a7e8a4e78 100644 --- a/dbms/src/Storages/StorageDistributed.cpp +++ b/dbms/src/Storages/StorageDistributed.cpp @@ -128,7 +128,7 @@ StorageDistributed::StorageDistributed( const String & remote_database_, const String & remote_table_, const String & cluster_name_, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_, const String & data_path_) : name(name_), columns(columns_), @@ -152,7 +152,7 @@ StorageDistributed::StorageDistributed( const String & remote_database_, const String & remote_table_, const String & cluster_name_, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_, const String & data_path_) : IStorage{materialized_columns_, alias_columns_, column_defaults_}, @@ -177,7 +177,7 @@ StoragePtr StorageDistributed::create( const String & remote_database_, const String & remote_table_, const String & cluster_name_, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_, const String & data_path_) { @@ -197,7 +197,7 @@ StoragePtr StorageDistributed::create( const String & remote_database_, const String & remote_table_, ClusterPtr & owned_cluster_, - Context & context_) + const Context & context_) { auto res = make_shared( name_, columns_, remote_database_, @@ -450,7 +450,7 @@ BlockInputStreams StorageDistributed::describe(const Context & context, const Se /** The functionality of shard_multiplexing is not completed - turn it off. * (Because connecting connections to different shards within a single thread is not done in parallel.) - * For more information, see https: //███████████.yandex-team.ru/METR-18300 + * For more information, see https://███████████.yandex-team.ru/METR-18300 */ bool enable_shard_multiplexing = false; diff --git a/dbms/src/Storages/StorageDistributed.h b/dbms/src/Storages/StorageDistributed.h index 592220ea47..b2b7f055d2 100644 --- a/dbms/src/Storages/StorageDistributed.h +++ b/dbms/src/Storages/StorageDistributed.h @@ -41,7 +41,7 @@ public: const String & remote_database_, /// database on remote servers. const String & remote_table_, /// The name of the table on the remote servers. const String & cluster_name, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_, const String & data_path_); @@ -51,7 +51,7 @@ public: const String & remote_database_, /// database on remote servers. const String & remote_table_, /// The name of the table on the remote servers. ClusterPtr & owned_cluster_, - Context & context_); + const Context & context_); std::string getName() const override { return "Distributed"; } std::string getTableName() const override { return name; } @@ -110,7 +110,7 @@ private: const String & remote_database_, const String & remote_table_, const String & cluster_name_, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_ = nullptr, const String & data_path_ = String{}); @@ -123,7 +123,7 @@ private: const String & remote_database_, const String & remote_table_, const String & cluster_name_, - Context & context_, + const Context & context_, const ASTPtr & sharding_key_ = nullptr, const String & data_path_ = String{}); -- GitLab