apache / apache/brpc

云存储场景下的 RDMA 优化

Open
#2,344 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
17.6k
Forks
4.1k
Avg merge
2d 12h
Merged PRs (30d)
69

Description

**Is your feature request related to a problem? (你需要的功能是否与某个问题有关?)**
在云存储场景中,随着 RDMA 的广泛使用,现有开源 brpc 的性能出现了明显的瓶颈:1)采用 completion channel + epoll 接收消息,不仅引入中断开销,还产生更多内核态切换;2)brpc 采用的 bthread 线程模型也具有较高的开销。
我们注意到你们在 ApacheCon 的技术报告,报告中所述的设计方案符合我们的需求。希望能将这些功能汇入主线,提高 brpc 的适用性。
https://apachecon.com/acasia2022/zh/sessions/rpc-1184.html

**Describe the solution you'd like (描述你期望的解决方法)**
拿掉目前基于 epoll 的处理逻辑,改用 busy polling (DPDK 或 RDMA)。正如你们在技术报告中所述,修改主要包含三个方面:
- 一是对bRPC线程模型的改造,接收请求消息 —— 处理 —— 发送响应消息在单一线程上连续执行(参考 https://github.com/apache/brpc/issues/1434 );
- 二是对bRPC代码以及使用模块,主要包括原子变量、IOBuf以及序列化的裁剪和优化;
- 三是对bRPC使用rdma的改造设计,充分发挥rdma的性能优势。

**Describe alternatives you've considered (描述你想到的折衷方案)**
N/A

**Additional context/screenshots (更多上下文/截图)**
N/A

Contributor guide

Open the contributing guide

Research direction

Start by reading issue #1434 and the linked ApacheCon technical report to understand the proposed single-threaded request path and busy-polling design. Then trace brpc’s current completion-channel/epoll handling, bthread model, IOBuf, atomic-variable, and serialization paths; done would require a scoped design and implementation plan for RDMA-oriented changes, but no files or tests are identified here.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend, cloud, networking, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.