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

Add exception handling in server for when gRPC client closes stream #3272

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

namannandan
Copy link
Collaborator

@namannandan namannandan commented Jul 31, 2024

Description

Based on fix demonstrated in #3267 with additional exception handling.

The following cases are handled:

  1. If the stream has already been closed by the client, we won't attempt to send a response since we check to see if the stream is still open before attempting to send a response.
  2. If the stream gets closed after we check to see if the stream is open but before we attempt to send a response, then the exception IllegalStateException is caught and handled. This should prevent the worker from dying.
  3. Extend the above two fixes to management and OIP requests as well.

Fixes #3087

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

Feature/Issue validation/testing

  • CI

  • Manual testing (in-progress)

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.

TorchServe crashes in production with `WorkerThread - IllegalStateException error'
1 participant