mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-29 11:02:08 +00:00
fix
This commit is contained in:
parent
78d8557a56
commit
ba44d7260e
@ -110,8 +110,6 @@ void Keeper::createServer(const std::string & listen_host, const char * port_nam
|
||||
}
|
||||
catch (const Poco::Exception &)
|
||||
{
|
||||
std::string message = "Listen [" + listen_host + "]:" + std::to_string(port) + " failed: " + getCurrentExceptionMessage(false);
|
||||
|
||||
if (listen_try)
|
||||
{
|
||||
LOG_WARNING(&logger(), "Listen [{}]:{} failed: {}. If it is an IPv6 or IPv4 address and your host has disabled IPv6 or IPv4, "
|
||||
|
@ -549,7 +549,7 @@ LDAPClient::SearchResults LDAPClient::search(const SearchParams & search_params)
|
||||
|
||||
if (rc != LDAP_SUCCESS)
|
||||
{
|
||||
String message = "LDAP search failed";
|
||||
String message;
|
||||
|
||||
const char * raw_err_str = ldap_err2string(rc);
|
||||
if (raw_err_str && *raw_err_str != '\0')
|
||||
@ -570,7 +570,7 @@ LDAPClient::SearchResults LDAPClient::search(const SearchParams & search_params)
|
||||
message += matched_msg;
|
||||
}
|
||||
|
||||
throw Exception::createDeprecated(message, ErrorCodes::LDAP_ERROR);
|
||||
throw Exception(ErrorCodes::LDAP_ERROR, "LDAP search failed{}", message);
|
||||
}
|
||||
|
||||
break;
|
||||
|
@ -429,12 +429,10 @@ void ProtobufReader::ignoreGroup()
|
||||
|
||||
[[noreturn]] void ProtobufReader::throwUnknownFormat() const
|
||||
{
|
||||
throw Exception::createDeprecated(
|
||||
std::string("Protobuf messages are corrupted or don't match the provided schema.")
|
||||
+ (root_message_has_length_delimiter
|
||||
throw Exception(ErrorCodes::UNKNOWN_PROTOBUF_FORMAT, "Protobuf messages are corrupted or don't match the provided schema.{}",
|
||||
root_message_has_length_delimiter
|
||||
? " Please note that Protobuf stream is length-delimited: every message is prefixed by its length in varint."
|
||||
: ""),
|
||||
ErrorCodes::UNKNOWN_PROTOBUF_FORMAT);
|
||||
: "");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -163,12 +163,8 @@ static bool compareRetentions(const Retention & a, const Retention & b)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
String error_msg = "age and precision should only grow up: "
|
||||
+ std::to_string(a.age) + ":" + std::to_string(a.precision) + " vs "
|
||||
+ std::to_string(b.age) + ":" + std::to_string(b.precision);
|
||||
throw Exception::createDeprecated(
|
||||
error_msg,
|
||||
DB::ErrorCodes::BAD_ARGUMENTS);
|
||||
throw Exception(DB::ErrorCodes::BAD_ARGUMENTS, "Age and precision should only grow up: {}:{} vs {}:{}",
|
||||
a.age, a.precision, b.age, b.precision);
|
||||
}
|
||||
|
||||
bool operator==(const Retention & a, const Retention & b)
|
||||
|
@ -352,7 +352,10 @@ def test_authentication():
|
||||
|
||||
|
||||
def test_logs():
|
||||
logs = query_and_get_logs("SELECT 1", settings={"send_logs_level": "debug"})
|
||||
logs = query_and_get_logs(
|
||||
"SELECT has(groupArray(number), 42) FROM numbers(1000)",
|
||||
settings={"send_logs_level": "debug"},
|
||||
)
|
||||
assert "SELECT 1" in logs
|
||||
assert "Read 1 rows" in logs
|
||||
assert "Peak memory usage" in logs
|
||||
|
Loading…
Reference in New Issue
Block a user