Merged
Conversation
⏱️ Benchmark results
|
candiduslynx
approved these changes
Dec 17, 2022
erezrokah
approved these changes
Dec 18, 2022
Member
erezrokah
left a comment
There was a problem hiding this comment.
May I suggest we don't set the error code at all and only keep the default Unknown for now?
We don't use neither one as we never check the error code on the client side.
I don't have a strong opinion here so approving
Contributor
Author
|
We indeed are not using it either way as most of the error are internal and thus fatal but this will be just nicer to the user i.e seeing |
kodiakhq bot
pushed a commit
that referenced
this pull request
Dec 19, 2022
🤖 I have created a release *beep* *boop* --- ## [1.12.6](v1.12.5...v1.12.6) (2022-12-18) ### Bug Fixes * Add better logging/metric per table ([#513](#513)) ([da36396](da36396)) * Improve formatting of newlines in markdown files ([#492](#492)) ([e48ff90](e48ff90)) * Include table name in logs on panic ([#505](#505)) ([a0b8a46](a0b8a46)) * Move source & destination plugin code to separate packages ([#516](#516)) ([6733785](6733785)) * Use correct error codes ([#514](#514)) ([8b53d76](8b53d76)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is uses correct error codes for gRPC in most places. We use Internal and this is the intedded error code for server errors. This is also used by the grpc server as well but it doesn't mean it is only for the gRPC code. See documentation:
https://pkg.go.dev/google.golang.org/grpc/codes#Code
https://cloud.google.com/apis/design/errors
The right codes for internal error are
Unknown(The default one) andInternal