Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gRPC: Should not call onComplete after onError #71

Closed
zackangelo opened this issue Jan 7, 2016 · 0 comments
Closed

gRPC: Should not call onComplete after onError #71

zackangelo opened this issue Jan 7, 2016 · 0 comments

Comments

@zackangelo
Copy link
Contributor

We're calling onComplete after onError when converting a call's result from a Try to a StreamObserver. This violates the interface contract of StreamObserver, which says onError should be the last method called: https://github.com/grpc/grpc-java/blob/master/stub/src/main/java/io/grpc/stub/StreamObserver.java#L63

This causes the stream to be double-closed, resulting in a IllegalStateException when an error occurs inside of a gRPC service method.

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

No branches or pull requests

1 participant