pandaapo commented on code in PR #4644:
URL: https://github.com/apache/eventmesh/pull/4644#discussion_r1426149058
##########
eventmesh-sdks/eventmesh-sdk-java/src/main/java/org/apache/eventmesh/client/grpc/consumer/SubStreamHandler.java:
##########
@@ -99,8 +99,7 @@ public void onNext(final CloudEvent message) {
@Override
public void onError(final Throwable t) {
- LogUtils.error(log, "Received Server side error", t);
- close();
+ log.error("Received Server side error", t);
Review Comment:
After StreamObserver#onCompleted is called, the connection should not be
disconnected, and the client can continue to receive responses from the server.
But this source code comment reminded me that although the connection was not
disconnected, gRPC indicates that the client is no longer sending messages to
the server. (@hhuang1231 This can be seen as a supplement to this reply
https://github.com/apache/eventmesh/issues/4587#issuecomment-1833101500, which
may be the reason why heartbeat cannot be sent.)
StreamObserver#onCompleted被调用以后,应该并不会断开连接,客户端可以继续接收服务端的响应。但是这段源码注释提醒了我,虽然连接没断开,但是gRPC这时标识客户端不再发送消息给服务端。(@hhuang1231
这可以看作是对这条回复https://github.com/apache/eventmesh/issues/4587#issuecomment-1833101500
的补充,可能这就是无法发送心跳的原因。)
##########
eventmesh-sdks/eventmesh-sdk-java/src/main/java/org/apache/eventmesh/client/grpc/consumer/SubStreamHandler.java:
##########
@@ -99,8 +99,7 @@ public void onNext(final CloudEvent message) {
@Override
public void onError(final Throwable t) {
- LogUtils.error(log, "Received Server side error", t);
- close();
+ log.error("Received Server side error", t);
Review Comment:
After StreamObserver#onCompleted is called, the connection should not be
disconnected, and the client can continue to receive responses from the server.
But this source code comment reminded me that although the connection was not
disconnected, gRPC indicates that the client is no longer sending messages to
the server. (@hhuang1231 This can be seen as a supplement to this reply
https://github.com/apache/eventmesh/issues/4587#issuecomment-1833101500, which
may be the reason why heartbeat cannot be sent.)
StreamObserver#onCompleted被调用以后,应该并不会断开连接,客户端可以继续接收服务端的响应。但是这段源码注释提醒了我,虽然连接没断开,但是gRPC这时标识客户端不再发送消息给服务端。(@hhuang1231
这可以看作是对这条回复https://github.com/apache/eventmesh/issues/4587#issuecomment-1833101500
的补充,可能这就是无法发送心跳的原因。)
--
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]