MJY-HUST commented on code in PR #2645:
URL: https://github.com/apache/brpc/pull/2645#discussion_r1635186376
##
src/bthread/key.cpp:
##
@@ -226,14 +270,16 @@ void return_keytable(bthread_keytable_pool_t* pool,
KeyTable* kt) {
delete kt;
return;
}
-std
MJY-HUST commented on PR #2645:
URL: https://github.com/apache/brpc/pull/2645#issuecomment-2161206047
> 对这个场景有点疑问,如果bthread生命周期很短,为什么还要使用bthread_local变量呢,用pthread
local、局部变量或者通过函数参数传递不行吗
场景是:使用brpc框架通信,server下面接着一个数据库。使用bthread
pool用于处理数据库的查询请求,数据库内部的实现使用了bthread级别的锁和tls来避免阻塞线程。数据库内部
MJY-HUST commented on code in PR #2645:
URL: https://github.com/apache/brpc/pull/2645#discussion_r1635199601
##
src/bthread/key.cpp:
##
@@ -204,14 +205,57 @@ class BAIDU_CACHELINE_ALIGNMENT KeyTable {
SubKeyTable* _subs[KEY_1STLEVEL_SIZE];
};
+class KeyTableList {
+publi
GreateCode opened a new pull request, #2661:
URL: https://github.com/apache/brpc/pull/2661
### What problem does this PR solve?
Issue Number:
Problem Summary:
**h2 rpc_dump时 内存泄漏**。
具体是http和h2都走ProcessHttpRequest方法,在处理rpc_dump时,先AskToBeSampled创建堆对象再判is_http2,若是http2无释