You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by "ivanallen (via GitHub)" <gi...@apache.org> on 2023/12/11 10:54:09 UTC

[I] memory leak in brpc::Server (brpc)

ivanallen opened a new issue, #2470:
URL: https://github.com/apache/brpc/issues/2470

   **Describe the bug (描述bug)**
   
   ![image](https://github.com/apache/brpc/assets/12481610/ee76e10a-2411-4e71-991d-a3889a957232)
   
   ![image](https://github.com/apache/brpc/assets/12481610/0fd69cb4-bdaa-41ef-a730-d76d628648ce)
   
   
   **To Reproduce (复现方法)**
   
   什么也没干,也会报泄露
   
   ![image](https://github.com/apache/brpc/assets/12481610/986811db-dfb8-451d-a7a9-8ae1fd333fd6)
   
   
   
   **Expected behavior (期望行为)**
   
   
   
   **Versions (各种版本)**
   OS:
   Compiler:
   brpc:
   protobuf:
   
   **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: dev-unsubscribe@brpc.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] memory leak in brpc::Server (brpc)

Posted by "lorinlee (via GitHub)" <gi...@apache.org>.
lorinlee commented on issue #2470:
URL: https://github.com/apache/brpc/issues/2470#issuecomment-1857794710

   这里的内存泄漏是符合预期的,可以参考 Server::Join的注释
   ![image](https://github.com/apache/brpc/assets/16054841/79727fc9-c018-43f4-b82d-42f0f54da42d)
   


-- 
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: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] memory leak in brpc::Server (brpc)

Posted by "lorinlee (via GitHub)" <gi...@apache.org>.
lorinlee closed issue #2470: memory leak in brpc::Server
URL: https://github.com/apache/brpc/issues/2470


-- 
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: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] memory leak in brpc::Server (brpc)

Posted by "chenBright (via GitHub)" <gi...@apache.org>.
chenBright commented on issue #2470:
URL: https://github.com/apache/brpc/issues/2470#issuecomment-2572500799

   1. 如果编译bRPC库的时候开了ASan,#2858 会自动忽略这些内存泄漏。
   2. 如果没开,代码里使用LSan注解也可以忽略:
   ```c++
   brpc::Server server;
   {
       ANNOTATE_SCOPED_MEMORY_LEAK;
       server.Start(...);
   }
   ```


-- 
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: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org