Skip to content

Termination of idle requests and connections #921

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

Closed
thomasfrisko opened this issue May 22, 2020 · 2 comments
Closed

Termination of idle requests and connections #921

thomasfrisko opened this issue May 22, 2020 · 2 comments
Labels
question Further information is requested

Comments

@thomasfrisko
Copy link

thomasfrisko commented May 22, 2020

We are switching from C-based gRPC to .NET gRPC implementation. In the C-based implementation we have a lot of options to configure keep-alive described here: https://github.com/grpc/grpc/blob/master/doc/keepalive.md we use this to ensure that idle connections are removed in order to avoid resource leaks. These kind of options do not seem to be present in .NET gRPC. This is problematic when using client and bidirectional streaming calls as the execution will be stuck at "MoveNext()" which will never return or throw an exception. Also, the TCP connection is never removed.

The only solution we have found so far is to handle it in the application layer where we have a timeout if no data has been received from the client. This will both end the request and the TCP connection, however, this is not a great solution since we will have to do this for all streaming calls and if this is forgotten it will cause memory leak.
Is this the only way to handle idle request/tcp connections are we missing something?

@thomasfrisko thomasfrisko added the question Further information is requested label May 22, 2020
@JuliusSweetland
Copy link

I've queried this in #770

@JamesNK
Copy link
Member

JamesNK commented May 27, 2020

Please contribute to the discussion at #770

@JamesNK JamesNK closed this as completed May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants