Skip to content

Conversation

@MrMage
Copy link
Collaborator

@MrMage MrMage commented Mar 5, 2019

Otherwise, the server will never respond to a call that gets closed without the client sending a response.

In addition, we introduce a method sendErrorStatus (happy to discuss naming) on BaseCallHandler that sends an error status to the client while ensuring that all call context promises are fulfilled. This method is required (and needs to be overridden) because only the concrete call subclass knows which promises need to be fulfilled.

… of zero request messages being sent.

Otherwise, the server will never respond to a call that gets closed without the client sending a response.
@MrMage MrMage requested a review from rebello95 March 5, 2019 10:43
@MrMage
Copy link
Collaborator Author

MrMage commented Mar 5, 2019

/cc @glbrntt for review (can't request a review for you through the GitHub "Reviewers" list for some reason)

…- it's easier to test this via HTTP1 than having to set up an HTTP2 client.
@MrMage
Copy link
Collaborator Author

MrMage commented Mar 5, 2019

@glbrntt I've slightly extended the scope of this PR; please take another look.


private func gRPCWebOKTrailers() -> Data {
var data = "grpc-status: 0\r\ngrpc-message: OK".data(using: .utf8)!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revert

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there's still trailing whitespace here

@MrMage MrMage requested a review from rebello95 March 5, 2019 19:42
@MrMage
Copy link
Collaborator Author

MrMage commented Mar 5, 2019

@rebello95 please take another look, especially at the unresolved conversations. Feel free to squash-and-merge if you are satisfied with the current revision.


private func gRPCWebOKTrailers() -> Data {
var data = "grpc-status: 0\r\ngrpc-message: OK".data(using: .utf8)!
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there's still trailing whitespace here

@MrMage
Copy link
Collaborator Author

MrMage commented Mar 6, 2019

Looks like I forgot to actually commit and push my fixes, sorry about that! @rebello95, please take one final look.

@rebello95 rebello95 merged commit d4a6366 into master Mar 6, 2019
@MrMage MrMage deleted the zero-requests branch April 4, 2019 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants