wayslog commented on issue #2142:
URL: https://github.com/apache/brpc/issues/2142#issuecomment-1453365435

   > 
目前RedisRequest支持批量,但是多个批量请求的key可能hash到不同的server,而当前一次RPC过程会把请求都发到同一个server,所以可能要加个限制,一次RPC的多个批量请求的key必须相同,否则实现起来会很复杂
   
   可以不相同,只要 key hash 之后的 slot 相同就可以了。另外现在的 redis 
客户端大部分其实都未做拆分,这个拆分了之后对一些特殊的命令比如 MSETNX 之类产生不可知的影响。
   我们这里可以先只支持同 server 的请求,把自动拆 key (涉及到的命令主要有 MGET/MSET/DEL/EXISTS... 
这几个)的作为后续的支持实现。
   
   > 
目前Controller能拿到LB,但是拿不到NamingService对象。Controller耦合NamingService似乎不是一个好主意,可以考虑只更新LB就可以。
   
   我也感觉耦合 NamingService 不是一个好主意。NamingService 可以通过周期性的发送命令自己更新自己。
   
   > 这里需要一定的抽象,可以抽象一个通用的Controller Redirect流程
   
   Controller 这里重定向逻辑作为一个插件或者策略组什么的插入 Controller 里吧,继承下来感觉不如另加逻辑。就是我得注意一下不要把 
Controller 污染。
   
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to