We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug (描述bug) 在从 /brpc_metrics 采集 metric 的时候, 请求由 bthread 执行, 而此时会为了锁住全局 VarMap 获取一个 pthread mutex, 当有一个用户定义的 metric 中出现了 bthread yield, 则会引起死锁.
/brpc_metrics
To Reproduce (复现方法) 使用 PassiveStatus, 然后在这个 metric 的计算函数中引入一个 bthread::Mutex 的获取, 即会引起死锁. 其他的会产生 bthread yield 的同步原语均可引起同样行为.
PassiveStatus
bthread::Mutex
Expected behavior (期望行为) 个人认为在这里出现 pthread mutex 是反直觉的, 尤其是在文档强调不要令 pthread mutex 和 bthread mutex 混用的情况下. 希望可以:
Versions (各种版本) OS: Compiler: brpc: protobuf:
Additional context/screenshots (更多上下文/截图)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug (描述bug)
在从
/brpc_metrics
采集 metric 的时候, 请求由 bthread 执行, 而此时会为了锁住全局 VarMap 获取一个 pthread mutex, 当有一个用户定义的 metric 中出现了 bthread yield, 则会引起死锁.To Reproduce (复现方法)
使用
PassiveStatus
, 然后在这个 metric 的计算函数中引入一个bthread::Mutex
的获取, 即会引起死锁. 其他的会产生 bthread yield 的同步原语均可引起同样行为.Expected behavior (期望行为)
个人认为在这里出现 pthread mutex 是反直觉的, 尤其是在文档强调不要令 pthread mutex 和 bthread mutex 混用的情况下. 希望可以:
Versions (各种版本)
OS:
Compiler:
brpc:
protobuf:
Additional context/screenshots (更多上下文/截图)
The text was updated successfully, but these errors were encountered: