Calling SendAndClose stream does not result io.EOF error

35 views
Skip to first unread message

torpido

unread,
May 17, 2023, 8:12:42 AM5/17/23
to grpc.io
hi,

Does anyone have any idea why when I call SendAndClose from the server stream I don't get an io.EOF error but instead the error is nil, so my stream is never closed?

Zach Reyes

unread,
May 17, 2023, 3:57:01 PM5/17/23
to grpc.io
Can you provide both the client and server code snippet (preferably reproducible), so we can run and see what's going on here.

torpido

unread,
May 17, 2023, 5:17:31 PM5/17/23
to grpc.io
I just realized that SendAndClose should not send EOF but simply indicate that the stream should be closed.
What I'm trying to achieve is for the gRPC server to close the streamhim self instead of waiting for the client to send EOF.
Can this be done from the gRPC server side? 

ב-יום רביעי, 17 במאי 2023 בשעה 22:57:01 UTC+3, Zach Reyes כתב/ה:
Reply all
Reply to author
Forward
0 new messages