apache / brpc

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 "better RPC".

Home Page:https://brpc.apache.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

通过python调用c++封装的通讯模块,底层使用brpc(baidu_std),如何让brpc的请求统一通过代理服务器进行转发

xiaohei-info opened this issue · comments

Describe the bug (描述bug)
尝试过在os中
export HTTP_PROXY="xx.xx.xx.xx:8080"
export HTTPS_PROXY="xx.xx.xx.xx:8080"
curl -x xx.xx.xx.xx:8080 目标ip:目标port
curl可以正常通过代理服务器转发到目标ip地址
但启动的python程序(调用编译好的C++通讯模块,底层使用brpc),默认使用baidu_std协议时,请求直接打到目标ip,没有经过代理服务器,将brpc_channel_protocol换为h2:grpc同样无法走代理服务器

To Reproduce (复现方法)

Expected behavior (期望行为)
请问如何设置brpc的代理服务器行为?

Versions (各种版本)
OS:
Compiler:
brpc:
protobuf:

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

目前 brpc 未支持这种 proxy 方式