You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2018/09/19 06:36:36 UTC

[GitHub] carryxyh commented on a change in pull request #2498: Optimize resultFuture callback

carryxyh commented on a change in pull request #2498: Optimize resultFuture callback
URL: https://github.com/apache/incubator-dubbo/pull/2498#discussion_r218682594
 
 

 ##########
 File path: dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/AsyncRpcResult.java
 ##########
 @@ -133,7 +133,7 @@ public Object recreate() throws Throwable {
     }
 
     public void thenApplyWithContext(Function<Result, Result> fn) {
-        this.resultFuture = resultFuture.thenApply(fn.compose(beforeContext).andThen(afterContext));
+        resultFuture.thenApply(fn.compose(beforeContext).andThen(afterContext));
 
 Review comment:
   Thank you for your answer, I understand. I tried two ways to solve this problem, but for now it is most appropriate to use closures.
   👍 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org