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 2021/10/27 03:30:31 UTC

[GitHub] [dubbo] EarthChen commented on a change in pull request #9140: [3.0-Triple] Fix missing response and duplicate trailers

EarthChen commented on a change in pull request #9140:
URL: https://github.com/apache/dubbo/pull/9140#discussion_r737074381



##########
File path: dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/TripleClientRequestHandler.java
##########
@@ -51,9 +51,14 @@ private void writeRequest(ChannelHandlerContext ctx, final Request req, final Ch
         streamChannelBootstrap.open()
             .addListener(future -> {
                 if (future.isSuccess()) {
-                    final Http2StreamChannel curChannel = (Http2StreamChannel) future.get();
+                    final Http2StreamChannel channel = (Http2StreamChannel) future.get();

Review comment:
       Why move ?

##########
File path: dubbo-rpc/dubbo-rpc-triple/src/main/java/org/apache/dubbo/rpc/protocol/tri/UnaryServerStream.java
##########
@@ -85,10 +85,12 @@ public void invoke() {
                 outboundTransportObserver().onMetadata(metadata, false);
                 final byte[] data = encodeResponse(response.getValue());
                 if (data == null) {
+                    transportError(GrpcStatus.fromCode(GrpcStatus.Code.INTERNAL)

Review comment:
       When method `encodeResponse`  returns null, it may be that encode threw an exception that was already handled in the method




-- 
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-unsubscribe@dubbo.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org