Skip to content

after stream.write() throw once, following correct stream.write() get buffered. #8882

@sulliwane

Description

@sulliwane

Hello,

from nodejs grpc server, if I write to a stream with BAD data, it will throw an error:

stream.on('error', console.log('nothing catched here');

function writeToStream(data) {
  try {
    stream.write(data)
  } catch (error) {
    console.log('catched the error here');
  }
}
writeToStream(correctData) // grpc client receive
writeToStream(badData); // grpc client NEVER receive
writeToStream(correctData); // grpc client NEVER receive

my problem is that the next time I write to this stream, with correct data, the grpc client never receives the correct data written to the stream...

@murgatroid99 Any idea on this one?

Many thanks!

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions