brpc icon indicating copy to clipboard operation
brpc copied to clipboard

brpc is an Industrial-grade RPC framework using C++ Language, which is often used in high performance system such as Search, Storage, Machine learning, Advertisement, Recommendation etc. "brpc" means...

Results 414 brpc issues
Sort by recently updated
recently updated
newest added

event_dispatcher.cpp 同时兼容Linux和Mac系统,大量使用了条件编译的宏,这种条件编译的代码占了这个文件的大部分。 导致这个代码文件可读性比较差,另外后续如果扩充其他操作系统、其他事件驱动的API,则event_dispatcher可维护性也比较差。 参考Redis中事件驱动库Ae的源码组织形式: ```c #ifdef HAVE_EVPORT #include "ae_evport.c" #else #ifdef HAVE_EPOLL #include "ae_epoll.c" #else #ifdef HAVE_KQUEUE #include "ae_kqueue.c" #else #include "ae_select.c" #endif #endif #endif ``` 使用include 源文件的方式来隔离不同的操作系统的实现差异,单个文件可读性大大提升,也方便后续扩充其他系统的支持(只需要添加一个新的文件即可) 新增的两个文件之所以后缀名之所以改成了cxx是因为当前的编译脚本会自动对cpp文件编译成 .o...

当前在我们线上场景发现bvar 线程始终是100%在运转的。所以我们在思考, 1,能否彻底关闭bvar 的sampler 线程?从代码来看,当前貌似没有关闭的gflag。 2,关闭了sampler 线程对brpc实际的影响是啥?仅仅是一些统计值看不了吗?如果我们不关心这些统计值的话,是不是就没有影响? 3,能否在后续的迭代版本中增加一个gflag,用来控制是否开启sampler线程? 辛苦帮忙解答一下,谢谢,Thanks♪(・ω・)ノ

feature

bthread在读磁盘的时候会block整个线程,有没有计划引入io_uring然后采用异步IO的方式减少线程阻塞?

feature

Trying to merge rdma implementation into master. This implementation is little different from previous rdma branch. I remove some proved useless code and try to improve the handshake process.

feature

**Describe the bug (描述bug)** 是否考虑在优雅退出时,stop and join 一些框架的常驻线程(worker线程、timer线程、bvar相关线程)?因为在退出的时候,全局变量或者静态变量析构后,常驻线程有几率访问到这些变量,存在coredump风险。相关issue:https://github.com/apache/incubator-brpc/issues/1594 、https://github.com/apache/incubator-brpc/issues/1726 、https://github.com/apache/incubator-brpc/issues/1634 **To Reproduce (复现方法)** 1. 通过graceful_quit_on_sigterm开启优雅退出功能; 2. 程序启动的时候,创建一个协程,协程的主要逻辑是`while(true) { /* 访问全局变量 */ }`; 3. 发送SIGTERM或者SIGINT给进程,让其优雅退出。 4. 这样,协程的循环里有几率访问到析构的全局变量,导致程序coredump。 **Expected behavior (期望行为)** 规避常驻线程在进程优雅退出时的coredump风险。...

good first issue

通过ServerOption自定义Server的Bvar prefix。 目前bvar默认的前缀是rpc_server_{server监听的port},但是存在如下问题: 1. 由于port改变(如使用range port或者其他port可能会改变的场景)导致bvar name变化,使得配置的dashboard和监控失效 2. 为了支持IPV6和Unix Domain socket,引入了ExtendedEndPoint,不过生成prefix存在BUG,会固定用EXTENDED_ENDPOINT_PORT(123456789)生成前缀(rpc_server_123456789),导致不同的Server bvar前缀相同。虽然修复不难,但是Unix Domain socket不太好处理,因为没有port信息,如果用file_path的话又太长。 基于以上考虑,最好还是用户通过ServerOption传入Server name生成prefix,如果name为空,则保持原来的逻辑。

issue: #https://github.com/apache/incubator-brpc/issues/1760 支持服务纬度的健康检查