wwbmmm commented on code in PR #2923:
URL: https://github.com/apache/brpc/pull/2923#discussion_r2009696732


##########
src/brpc/server.h:
##########
@@ -601,6 +601,16 @@ class Server {
     int MaxConcurrencyOf(google::protobuf::Service* service,
                          const butil::StringPiece& method_name) const;
 
+    // Reset max_concurrency associated with a method.
+    int ResetMaxConcurrencyOf(const butil::StringPiece& full_method_name,

Review Comment:
   突然发现一个问题,MaxConcurrencyOf方法可以返回一个 AdaptiveMaxConcurrency& 类型
   可以直接用server.MaxConcurrencyOf("xxx") = concurrency; 
来重新设置新值,就不用增加ResetMaxConcurrency方法
   不过可能需要修改下AdaptiveMaxConcurrency::operator= 方法,增加一些callback逻辑来生效新的concurrency



-- 
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.

To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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

Reply via email to