You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@brpc.apache.org by "condy0919 (via GitHub)" <gi...@apache.org> on 2026/04/23 19:29:06 UTC
[I] 给 dummy server 增加一个 Stop 函数 (brpc)
condy0919 opened a new issue, #3280:
URL: https://github.com/apache/brpc/issues/3280
**Is your feature request related to a problem?** yes
发生在客户端场景,客户端的 brpc::Socket 在 SetFailed 后会启动一个健康检查任务。而如果此时正好客户端被 `C-c` 掉,那么这个健康检查任务仍旧会调用 `Connect(..)` 函数。当前 brpc 中有许多全局变量,如 g_dummy_server, 它们不会参与析构流程,但是如果 `::connect(..)` 函数被 `hijack_connect` 给劫持,且 `hijack_connect` 中有访问非 pod static 变量(这个 static 变量析构已发生)就会出现状态异常。
**Describe the solution you'd like**
我的想法是添加一个新的函数 `StopDummyServer`
**Describe alternatives you've considered**
**Additional context/screenshots**
--
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: issues-unsubscribe@brpc.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@brpc.apache.org
For additional commands, e-mail: issues-help@brpc.apache.org
Re: [I] 给 dummy server 增加一个 Stop 函数 (brpc)
Posted by "condy0919 (via GitHub)" <gi...@apache.org>.
condy0919 closed issue #3280: 给 dummy server 增加一个 Stop 函数
URL: https://github.com/apache/brpc/issues/3280
--
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: issues-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@brpc.apache.org
For additional commands, e-mail: issues-help@brpc.apache.org
Re: [I] 给 dummy server 增加一个 Stop 函数 (brpc)
Posted by "condy0919 (via GitHub)" <gi...@apache.org>.
condy0919 commented on issue #3280:
URL: https://github.com/apache/brpc/issues/3280#issuecomment-4307918481
健康检查发生在 TimerThread, 我似乎应该也对 TimerThread 对一个优雅退出? @chenBright
--
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: issues-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@brpc.apache.org
For additional commands, e-mail: issues-help@brpc.apache.org