You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by GitBox <gi...@apache.org> on 2019/12/12 09:05:40 UTC

[GitHub] [incubator-brpc] yockie opened a new issue #995: 能否支持过载时fastfail回调

yockie opened a new issue #995: 能否支持过载时fastfail回调
URL: https://github.com/apache/incubator-brpc/issues/995
 
 
   **Is your feature request related to a problem? (你需要的功能是否与某个问题有关?)**
   我们的server期望加上限流功能,考虑使用brpc的自适应限流功能,减少测试工作量。但自适应限流目前超过最大并发度的请求会被拒绝(返回ELIMIT错误)。但我们期望超过最大并发度的请求可以回调我们提供的fastfail函数,返回给client,原因如下:
   1.我们期望、也能接受server端内部处理过载情况(设置缺省值返回给client)
   2.client端(其他语言)还不支持重试功能
   3.需要在fastfail中加一些报警打点之类
   
   **Describe the solution you'd like (描述你期望的解决方法)**
   期望增加使用方传入fastfail回调函数的功能,在过载时调用这个fastfail函数
   
   **Describe alternatives you've considered (描述你想到的折衷方案)**
   折中方案:或者提供查询当前server的_concurrency值的只读函数,使用方拿来跟server->options().max_concurrency比较、判断是否走fastfail逻辑
   
   **Additional context/screenshots (更多上下文/截图)**
   无。
   
   非常感谢!
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org