It is typical for grpc client streams to receive a final response from the server after ending the client stream. This wasn't implemented in ts-protoc-gen as described and exemplified in https://github.com/improbable-eng/ts-protoc-gen/issues/105. This PR fixes that.
Changes
Updated code generation for client stream (RequestStreams) onEnd callbacks to take an additional resp: ResT | undefined parameter to which the server response can be passed.
Updated generated grpc client code to get the server response and pass it to the onEnd listeners.
Updated the generated Typescript definitions to reflect all this
Generated example/test code in the repo so it reflects these changes
Added a test to test these changes
Verification
Added a test in the client streaming tests that specifies the mock grpc transport return a message, and verifies that message was received.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
It is typical for grpc client streams to receive a final response from the server after ending the client stream. This wasn't implemented in ts-protoc-gen as described and exemplified in https://github.com/improbable-eng/ts-protoc-gen/issues/105. This PR fixes that.
Changes
RequestStream
s)onEnd
callbacks to take an additionalresp: ResT | undefined
parameter to which the server response can be passed.onEnd
listeners.Verification
Added a test in the client streaming tests that specifies the mock grpc transport return a message, and verifies that message was received.