About this project

Apache bRPC is an open-source C++ RPC framework intended for performance-sensitive distributed systems such as search, storage, machine learning, advertising, and recommendation services. A bRPC server can communicate through multiple protocols on the same port, including HTTP/HTTPS, HTTP/2 and gRPC, Redis, Memcached, Thrift, RTMP/FLV/HLS, RDMA, and several Baidu-inherited RPC protocols. It can expose RESTful interfaces and map between JSON and protobuf messages. Servers may process requests synchronously or asynchronously. Clients support synchronous, asynchronous, and semi-synchronous calls. Combo channels provide a declarative way to issue sharded or parallel requests. The framework also includes backup requests, circuit breaking, automatic concurrency limiting, and load-balancing strategies such as round-robin, random, and consistent hashing. Naming-service integrations mentioned include DNS, ZooKeeper, and etcd. bRPC provides built-in HTTP-accessible services for status, variables, connections, flags, RPC tracing, and CPU, heap, and contention profiling. Its tooling includes rpc_press, rpc_replay, rpc_view, HTTP benchmarking, and parallel HTTP utilities. The project also documents bthread for user-space threading, bvar for metrics, IOBuf for buffer management, and Wireshark protocol dissection. Developers can add new protocols or customize naming, load balancing, and other components. For highly available replicated services, the README points to braft, a separate Raft consensus implementation associated with the project. Documentation covers getting started, clients, servers, streaming RPC, media serving, debugging, memory management, IO, threading, load balancing, performance benchmarks, and examples.