CrazyHZM commented on code in PR #11063: URL: https://github.com/apache/dubbo/pull/11063#discussion_r1044422633
########## dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/support/ForkingClusterInvoker.java: ########## @@ -83,28 +85,31 @@ public Result doInvoke(final Invocation invocation, List<Invoker<T>> invokers, L } RpcContext.getServiceContext().setInvokers((List) selected); final AtomicInteger count = new AtomicInteger(); - final BlockingQueue<Object> ref = new LinkedBlockingQueue<>(1); - for (final Invoker<T> invoker : selected) { + final CountDownLatch countDownLatch = new CountDownLatch(1); + AtomicReference<Object> result = new AtomicReference<>(); Review Comment: What is the advantage of changing LinkedBlockingQueue to CountDownLatch and AtomicReference? -- 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: notifications-unsubscr...@dubbo.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@dubbo.apache.org For additional commands, e-mail: notifications-h...@dubbo.apache.org