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

[🧹CHORE]: GRPC better errors handling #1001

Closed
1 task done
rustatian opened this issue Feb 10, 2022 · 1 comment · Fixed by roadrunner-server/grpc#38
Closed
1 task done

[🧹CHORE]: GRPC better errors handling #1001

rustatian opened this issue Feb 10, 2022 · 1 comment · Fixed by roadrunner-server/grpc#38
Assignees
Labels
C-enhancement Category: enhancement. Meaning improvements of current module, transport, etc.. P-GRPC Plugins: GRPC Y-high Priority: High
Milestone

Comments

@rustatian
Copy link
Member

rustatian commented Feb 10, 2022

No duplicates 🥲.

What should be improved or cleaned up?

At the moment, there is no way to distinguish between the applications errors and worker errors in the grpc plugin. The PHP client library sets the error protocol bit on any exception thrown from the PHP side, and this leads to worker restart on every exception.

I propose to fully implement the google errors API design and return errors in the worker's response. If this is a protocol error - RR will restart the worker. But in case of an application error, we will parse the response and respond with an error code w/o restarting a worker.

The PHP worker may put the error payload in the response context which is map[string]string (contains grpc headers (metadata)) at the moment and should be updated with the new structure.

@rustatian rustatian added C-enhancement Category: enhancement. Meaning improvements of current module, transport, etc.. P-GRPC Plugins: GRPC labels Feb 10, 2022
@rustatian rustatian self-assigned this Feb 10, 2022
@rustatian rustatian moved this to Backlog in General Feb 10, 2022
@rustatian rustatian moved this from Backlog to Discuss in General Feb 10, 2022
@rustatian rustatian added the Y-high Priority: High label Feb 10, 2022
@rustatian rustatian moved this from Discuss to In Progress in General Jul 13, 2022
@rustatian rustatian added this to the v2.11.0 milestone Jul 13, 2022
@rustatian
Copy link
Member Author

In progress, planned to be in the v2.11.0 (two weeks from now approx).

@rustatian rustatian changed the title [🧹 CHORE]: GRPC better errors handling [🧹CHORE]: GRPC better errors handling Jul 14, 2022
Repository owner moved this from In Progress to Unreleased in General Jul 18, 2022
@rustatian rustatian mentioned this issue Aug 18, 2022
6 tasks
@rustatian rustatian moved this from Unreleased to Done in General Aug 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: enhancement. Meaning improvements of current module, transport, etc.. P-GRPC Plugins: GRPC Y-high Priority: High
Projects
No open projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant