Skip to content

Commit 4533167

Browse files
committed
rdma polling mode process message in new bthread
1 parent 6d2d424 commit 4533167

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

src/brpc/input_messenger.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,12 @@ int InputMessenger::ProcessNewMessage(
331331
"destroyed when authentication failed";
332332
}
333333
}
334-
if (!m->is_read_progressive()) {
334+
#if BRPC_WITH_RDMA
335+
if (!m->is_read_progressive() && !rdma::FLAGS_rdma_use_polling)
336+
#else
337+
if (!m->is_read_progressive())
338+
#endif
339+
{
335340
// Transfer ownership to last_msg
336341
last_msg.reset(msg.release());
337342
} else {

src/brpc/rdma/rdma_endpoint.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ namespace brpc {
3636
class Socket;
3737
namespace rdma {
3838

39+
DECLARE_bool(rdma_use_polling);
3940
DECLARE_int32(rdma_poller_num);
4041
DECLARE_bool(rdma_edisp_unsched);
4142
DECLARE_bool(rdma_disable_bthread);

0 commit comments

Comments
 (0)