Skip to content

Commit f6721f8

Browse files
authored
debug level for "network-related error occured" log. EXT-1708 (#29179)
The same message will be printed during handshake result processing in the tcp proxy so no need to print it twice with NOTICE level.
1 parent 951d56b commit f6721f8

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

ydb/library/actors/interconnect/interconnect_handshake.cpp

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -244,8 +244,6 @@ namespace NActors {
244244
TString HandshakeKind;
245245
TMaybe<THolder<TProgramInfo>> ProgramInfo; // filled in in case of successful handshake; even if null
246246
TSessionParams Params;
247-
std::optional<TInstant> LastLogNotice;
248-
const TDuration MuteDuration = TDuration::Seconds(15);
249247
TMonotonic Deadline;
250248
TActorId HandshakeBroker;
251249
std::optional<TBrokerLeaseHolder> BrokerLeaseHolder;
@@ -749,8 +747,7 @@ namespace NActors {
749747

750748
// perform connection and log its result
751749
MainChannel.Connect(&PeerAddr);
752-
auto logPriority = std::exchange(LastLogNotice, std::nullopt) ? NActors::NLog::PRI_NOTICE : NActors::NLog::PRI_DEBUG;
753-
LOG_LOG_IC_X(NActorsServices::INTERCONNECT, "ICH05", logPriority, "connected to peer");
750+
LOG_LOG_IC_X(NActorsServices::INTERCONNECT, "ICH05", NActors::NLog::PRI_DEBUG, "connected to peer");
754751

755752
// Try to create rdma stuff
756753
CreateRdmaPrimitives();
@@ -1572,13 +1569,7 @@ namespace NActors {
15721569
PeerAddr.size() ? PeerAddr.data() : "<unknown>", explanation.data());
15731570

15741571
if (network) {
1575-
TInstant now = Now();
1576-
NActors::NLog::EPriority logPriority = NActors::NLog::PRI_DEBUG;
1577-
if (!LastLogNotice || now - *LastLogNotice > MuteDuration) {
1578-
logPriority = NActors::NLog::PRI_NOTICE;
1579-
LastLogNotice.emplace(now);
1580-
}
1581-
LOG_LOG_NET_X(logPriority, PeerNodeId, "network-related error occured on handshake: %s", msg.data());
1572+
LOG_LOG_NET_X(NActors::NLog::PRI_DEBUG, PeerNodeId, "network-related error occured on handshake: %s", msg.data());
15821573
} else {
15831574
// calculate log severity based on failure type; permanent failures lead to error log messages
15841575
auto severity = reason == TEvHandshakeFail::HANDSHAKE_FAIL_PERMANENT

0 commit comments

Comments
 (0)