diff options
author | Arne Juul <arnej@verizonmedia.com> | 2021-06-02 13:54:51 +0000 |
---|---|---|
committer | Arne Juul <arnej@verizonmedia.com> | 2021-06-02 13:54:51 +0000 |
commit | e8d528c3c1357b7c009734db01f63155bfb15613 (patch) | |
tree | 38bd9c4e9dc876dc8f56508b0be9253b057dbd68 /configd | |
parent | ec1eddbea020a6db5ba97cf5f2d8f45cc508ad95 (diff) |
also accept FRTE_RPC_WRONG_RETURN as "unavailable"
Diffstat (limited to 'configd')
-rw-r--r-- | configd/src/apps/sentinel/env.cpp | 4 | ||||
-rw-r--r-- | configd/src/apps/sentinel/outward-check.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/configd/src/apps/sentinel/env.cpp b/configd/src/apps/sentinel/env.cpp index 43ee263fb8f..e4174ee450d 100644 --- a/configd/src/apps/sentinel/env.cpp +++ b/configd/src/apps/sentinel/env.cpp @@ -111,8 +111,8 @@ std::map<std::string, std::string> specsFrom(const ModelConfig &model) { std::map<std::string, std::string> checkSpecs; for (const auto & h : model.hosts) { bool foundSentinelPort = false; - for (const auto & s : h.services) { - if (s.name == "config-sentinel") { + for (const auto & s : h.services) { + if (s.name == "config-sentinel") { for (const auto & p : s.ports) { if (p.tags.find("rpc") != p.tags.npos) { auto spec = fmt("tcp/%s:%d", h.name.c_str(), p.number); diff --git a/configd/src/apps/sentinel/outward-check.cpp b/configd/src/apps/sentinel/outward-check.cpp index bd6c22e7264..5fed69d0b6e 100644 --- a/configd/src/apps/sentinel/outward-check.cpp +++ b/configd/src/apps/sentinel/outward-check.cpp @@ -35,7 +35,8 @@ void OutwardCheck::RequestDone(FRT_RPCRequest *req) { _result = CcResult::REVERSE_FAIL; } } else if (req->GetErrorCode() == FRTE_RPC_NO_SUCH_METHOD || - req->GetErrorCode() == FRTE_RPC_WRONG_PARAMS) + req->GetErrorCode() == FRTE_RPC_WRONG_PARAMS || + req->GetErrorCode() == FRTE_RPC_WRONG_RETURN) { LOG(debug, "Connected OK to %s but no reverse connectivity check available", _spec.c_str()); _result = CcResult::REVERSE_UNAVAIL; @@ -43,7 +44,6 @@ void OutwardCheck::RequestDone(FRT_RPCRequest *req) { LOG(debug, "error on request to %s : %s (%d)", _spec.c_str(), req->GetErrorMessage(), req->GetErrorCode()); _result = CcResult::CONN_FAIL; - } _req->SubRef(); _req = nullptr; |