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

Describe error handling in RPC responses #150

Closed
3 tasks done
alexvanin opened this issue Apr 30, 2021 · 1 comment · Fixed by #176
Closed
3 tasks done

Describe error handling in RPC responses #150

alexvanin opened this issue Apr 30, 2021 · 1 comment · Fixed by #176
Assignees
Milestone

Comments

@alexvanin
Copy link
Contributor

alexvanin commented Apr 30, 2021

Error message transfer and handling is an important part of distributed decentralized information system. Transport protocol implementations provide error handling mechanisms, however they differ from each other:

  • gRPC inherits google API error model that returns error code, string message and optional details (supported in limited gRPC implementations),
  • Twirp provides error code, string message and string key-value map for meta data.

NeoFS API does not define transport layer. Therefore it is required to describe error handling on top of all transport implementations. To do that we should:

  • define enum of error types (or take it from gRPC or twrip implementation),
  • define error structure with error type and string details,
  • use error structure in ResponseMetaHeader.
@roman-khimov
Copy link
Member

I think any solution that would allow me to do errors.Is(err, apierrorslist.Something) is fine.

@cthulhu-rider cthulhu-rider self-assigned this Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Oct 4, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 6, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 6, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 12, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 15, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 15, 2021
cthulhu-rider pushed a commit to cthulhu-rider/neofs-api that referenced this issue Nov 15, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
cthulhu-rider pushed a commit that referenced this issue Nov 16, 2021
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 a pull request may close this issue.

3 participants