Skip to content

Commit 5f960ea

Browse files
committed
rename outlier detector to health checker
1 parent edea6c4 commit 5f960ea

File tree

3 files changed

+7
-9
lines changed

3 files changed

+7
-9
lines changed

polaris/plugin/health_checker/http_detector.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,12 @@ ReturnCode HttpHealthChecker::Init(Config* config, Context* /*context*/) {
3636

3737
request_path_ = config->GetStringOrDefault(kHttpRequestPathKey, kHttpRequestPathDefault);
3838
if (request_path_.empty() || request_path_[0] != '/') {
39-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s invalid", kPluginHttpHealthChecker,
39+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s invalid", kPluginHttpHealthChecker,
4040
kHttpRequestPathKey);
4141
return kReturnInvalidConfig;
4242
}
4343
timeout_ms_ = config->GetMsOrDefault(HealthCheckerConfig::kTimeoutKey,
4444
HealthCheckerConfig::kTimeoutDefault);
45-
4645
return kReturnOk;
4746
}
4847

polaris/plugin/health_checker/tcp_detector.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,18 +36,17 @@ ReturnCode TcpHealthChecker::Init(Config* config, Context* /*context*/) {
3636

3737
std::string send_package = config->GetStringOrDefault(kTcpSendPackageKey, kTcpSendPackageDefault);
3838
if (!send_package.empty() && !Utils::HexStringToBytes(send_package, &send_package_)) {
39-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s hexstring to bytes failed",
39+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s hexstring to bytes failed",
4040
kPluginTcpHealthChecker, kTcpSendPackageKey);
4141
return kReturnInvalidConfig;
4242
}
4343
std::string receive_package =
4444
config->GetStringOrDefault(kTcpReceivePackageKey, kTcpReceivePackageDefault);
4545
if (!receive_package.empty() && !Utils::HexStringToBytes(receive_package, &receive_package_)) {
46-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s hexstring to bytes failed",
46+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s hexstring to bytes failed",
4747
kPluginTcpHealthChecker, kTcpReceivePackageKey);
4848
return kReturnInvalidConfig;
4949
}
50-
5150
timeout_ms_ = config->GetMsOrDefault(HealthCheckerConfig::kTimeoutKey,
5251
HealthCheckerConfig::kTimeoutDefault);
5352
return kReturnOk;

polaris/plugin/health_checker/udp_detector.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,25 +38,25 @@ ReturnCode UdpHealthChecker::Init(Config* config, Context* /*context*/) {
3838

3939
std::string send_package = config->GetStringOrDefault(kUdpSendPackageKey, kUdpSendPackageDefault);
4040
if (send_package.empty()) {
41-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s should not be empty",
41+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s should not be empty",
4242
kPluginUdpHealthChecker, kUdpSendPackageKey);
4343
return kReturnInvalidConfig;
4444
}
4545
if (!Utils::HexStringToBytes(send_package, &send_package_)) {
46-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s hexstring to bytes failed",
46+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s hexstring to bytes failed",
4747
kPluginUdpHealthChecker, kUdpSendPackageKey);
4848
return kReturnInvalidConfig;
4949
}
5050
std::string receive_package =
5151
config->GetStringOrDefault(kUdpReceivePackageKey, kUdpReceivePackageDefault);
5252
if (!receive_package.empty()) {
5353
if (!Utils::HexStringToBytes(receive_package, &receive_package_)) {
54-
POLARIS_LOG(LOG_ERROR, "outlier detector[%s] config %s hexstring to bytes failed",
54+
POLARIS_LOG(LOG_ERROR, "health checker[%s] config %s hexstring to bytes failed",
5555
kPluginUdpHealthChecker, kUdpReceivePackageKey);
5656
return kReturnInvalidConfig;
5757
}
5858
}
59-
timeout_ms_ = config->GetMsOrDefault(HealthCheckerConfig ::kTimeoutKey,
59+
timeout_ms_ = config->GetMsOrDefault(HealthCheckerConfig::kTimeoutKey,
6060
HealthCheckerConfig::kTimeoutDefault);
6161
return kReturnOk;
6262
}

0 commit comments

Comments
 (0)