chenBright commented on code in PR #1814:
URL: https://github.com/apache/incubator-brpc/pull/1814#discussion_r912752151


##########
src/brpc/socket_map.cpp:
##########
@@ -301,6 +301,7 @@ void SocketMap::RemoveInternal(const SocketMapKey& key,
                 _this_map_bvar = new bvar::PassiveStatus<std::string>(
                     butil::StringPiece(namebuf, len), PrintSocketMap, this);
             }
+            s->DisableHealthCheck(); // disable health check

Review Comment:
   HealthCheckTask::OnTriggeringTask函数里的注释提到:
   
   > In our case, one reference comes from SocketMapInsert(socket_map.cpp), one 
reference is here.
   
   在Socket没有进行health 
check的时候调用DisableHealthCheck,表示SocketMapInsert的reference已经释放,没有必要再进行health 
check了。



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to