You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2019/04/24 03:18:55 UTC

[incubator-dubbo] branch 3.x-dev updated: get CompletableFuture before thenApply

This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch 3.x-dev
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git


The following commit(s) were added to refs/heads/3.x-dev by this push:
     new a95358d  get CompletableFuture before thenApply
a95358d is described below

commit a95358d7393ce5565e59318815ea3106c6336542
Author: ken.lj <ke...@gmail.com>
AuthorDate: Wed Apr 24 11:18:44 2019 +0800

    get CompletableFuture before thenApply
---
 .../main/java/org/apache/dubbo/rpc/protocol/thrift/ThriftProtocol.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dubbo-rpc/dubbo-rpc-thrift/src/main/java/org/apache/dubbo/rpc/protocol/thrift/ThriftProtocol.java b/dubbo-rpc/dubbo-rpc-thrift/src/main/java/org/apache/dubbo/rpc/protocol/thrift/ThriftProtocol.java
index 61c13cc..e80d61c 100644
--- a/dubbo-rpc/dubbo-rpc-thrift/src/main/java/org/apache/dubbo/rpc/protocol/thrift/ThriftProtocol.java
+++ b/dubbo-rpc/dubbo-rpc-thrift/src/main/java/org/apache/dubbo/rpc/protocol/thrift/ThriftProtocol.java
@@ -87,7 +87,7 @@ public class ThriftProtocol extends AbstractProtocol {
                 RpcContext.getContext().setRemoteAddress(channel.getRemoteAddress());
 
                 Result result = exporter.getInvoker().invoke(inv);
-                return result.thenApply(Function.identity());
+                return result.completionFuture().thenApply(Function.identity());
             }
 
             throw new RemotingException(channel,