mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-26 01:22:04 +00:00
CLICKHOUSE-3700: Fix empty password on replica query
This commit is contained in:
parent
d3cf85057b
commit
157067b127
@ -47,6 +47,7 @@ public:
|
||||
String current_user;
|
||||
String current_query_id;
|
||||
Poco::Net::SocketAddress current_address;
|
||||
String current_password;
|
||||
|
||||
/// When query_kind == INITIAL_QUERY, these values are equal to current.
|
||||
String initial_user;
|
||||
|
@ -564,6 +564,7 @@ void Context::setUser(const String & name, const String & password, const Poco::
|
||||
|
||||
client_info.current_user = name;
|
||||
client_info.current_address = address;
|
||||
client_info.current_password = password;
|
||||
|
||||
if (!quota_key.empty())
|
||||
client_info.quota_key = quota_key;
|
||||
|
@ -3277,7 +3277,7 @@ void StorageReplicatedMergeTree::sendRequestToLeaderReplica(const ASTPtr & query
|
||||
leader_address.host,
|
||||
leader_address.queries_port,
|
||||
leader_address.database,
|
||||
"", "", timeouts, "ClickHouse replica");
|
||||
context.getClientInfo().current_user, context.getClientInfo().current_password, timeouts, "ClickHouse replica");
|
||||
|
||||
RemoteBlockInputStream stream(connection, formattedAST(new_query), {}, context, &settings);
|
||||
NullBlockOutputStream output({});
|
||||
|
Loading…
Reference in New Issue
Block a user