chenBright commented on code in PR #2571: URL: https://github.com/apache/brpc/pull/2571#discussion_r1527744829
########## src/brpc/policy/streaming_rpc_protocol.cpp: ########## @@ -146,19 +148,24 @@ void SendStreamClose(Socket *sock, int64_t remote_stream_id, fm.set_frame_type(FRAME_TYPE_CLOSE); butil::IOBuf out; PackStreamMessage(&out, fm, NULL); - sock->Write(&out); + Socket::WriteOptions wopt; + wopt.ignore_eovercrowded = true; + sock->Write(&out, &wopt); } int SendStreamData(Socket* sock, const butil::IOBuf* data, int64_t remote_stream_id, int64_t source_stream_id) { + CHECK(sock != NULL); StreamFrameMeta fm; fm.set_stream_id(remote_stream_id); fm.set_source_stream_id(source_stream_id); fm.set_frame_type(FRAME_TYPE_DATA); fm.set_has_continuation(false); butil::IOBuf out; PackStreamMessage(&out, fm, data); - return sock->Write(&out); + Socket::WriteOptions wopt; + wopt.ignore_eovercrowded = true; Review Comment: 应该不会。SendStreamData这个函数应该是框架内部使用的,目前只有在server端响应上游建立好stream使用了。用户只持有StreamId,没法调用这个函数。 https://github.com/apache/brpc/blob/d4695c90092c2574d27e9f6eaa9dc9a86137be40/src/brpc/policy/baidu_rpc_protocol.cpp#L247-L264 -- 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: dev-unsubscr...@brpc.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org For additional commands, e-mail: dev-h...@brpc.apache.org