前端框架选型是企业提升开发效率与用户体验的关键因素
1541
2022-10-25
BRPC 即 Baidu-RPC ,是百度开源的 RPC 框架
中文版
An industrial-grade RPC framework used throughout Baidu, with 1,000,000+ instances(not counting clients) and thousands kinds of services, called "baidu-rpc" inside Baidu. Only C++ implementation is opensourced right now.
You can use it to:
Build a server that can talk in multiple protocols (on same port), or access all sorts of services restful http/https, h2/gRPC. using http/h2 in brpc is much more friendly than libcurl. Access protobuf-based protocols with HTTP/h2+json, probably from another language.redis and memcached, thread-safe, more friendly and performant than the official clients.rtmp/flv/hls, for building streaming services.hadoop_rpc (may be opensourced)rdma support (will be opensourced)thrift support, thread-safe, more friendly and performant than the official clients.all sorts of protocols used in Baidu: baidu_std, streaming_rpc, hulu_pbrpc, sofa_pbrpc, nova_pbrpc, public_pbrpc, ubrpc and nshead-based ones.Build HA distributed services using an industrial-grade implementation of RAFT consensus algorithm which is opensourced at braft Servers can handle requests synchronously or asynchronously.Clients can access servers synchronously, asynchronously, semi-synchronously, or use combo channels to simplify sharded or parallel accesses declaratively.Debug services via http, and run cpu, heap and contention profilers.Get better latency and throughput.Extend brpc with the protocols used in your organization quickly, or customize components, including naming services (dns, zk, etcd), load balancers (rr, random, consistent hashing)
Try it!
Read overview to know where brpc can be used and its advantages.Read getting started for building steps and play with examples.Docs: Performance benchmarkbvarbvar_c++ bthreadbthread or notthread-localExecution Queue Client BasicsError codeCombo channelsAccess http/h2Access gRPCAccess thriftAccess UBStreaming RPCAccess redisAccess memcachedBackup requestDummy server Server BasicsServe http/h2Serve gRPCServe thriftServe NsheadDebug server issuesServer pushAvalancheAuto ConcurrencyLimiterMedia Serverjson2pb Builtin Servicesstatusvarsconnectionsflagsrpczcpu_profilerheap_profilercontention_profiler Tools rpc_pressrpc_replayrpc_viewbenchmark_httpparallel_http Others IOBufStreaming LogFlatMapbrpc外功修炼宝典(training material)A tutorial on building large-scale services(training material)brpc internal(training material) RPC in depth New ProtocolAtomic instructionsIOThreading OverviewLoad BalancingLocality-awareConsistent HashingMemory ManagementTimer keepingbthread_id Use cases inside Baidu 百度地图api入口联盟DSPELF学习框架云平台代理服务
Contribute code
Please refer to here.
Feedback and Getting involved
Report bugs, ask questions or give suggestions by Github IssuesSubscribe mailing list(dev-subscribe@brpc.apache.org) to get updated with the project
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~