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 detailed errors to api responses #507

Merged
merged 2 commits into from
Apr 18, 2024

Conversation

sgotti
Copy link
Member

@sgotti sgotti commented Apr 15, 2024

In addition to the standard http error codes also report a detailed
error that contains an error code and an optional error detail. This is
required to better explain the reason of the reported error.

Since, by default if not handled in another way, an error returned by
an internal service is propagated by the gateway to the client, also
internal services returns detailed errors with exported error codes.

This patch adds an initial round of detailed errors. They are not stable
and will change in future.

@sgotti sgotti force-pushed the gateway_api_errors branch 3 times, most recently from 7d42f5a to 55b0f23 Compare April 15, 2024 15:41
Replace APIError/RemoteError Code and Message fields with an array of
detailed errors UserError (APIDetailedError/RemoteDetailedError) that
will contain a Code and optional error Details.
@sgotti sgotti force-pushed the gateway_api_errors branch from 55b0f23 to 110d6a0 Compare April 18, 2024 10:49
In addition to the standard http error codes also report a detailed
error that contains an error code and an optional error detail. This is
required to better explain the reason of the reported error.

Since, by default if not handled in another way, an error returned by
an internal service is propagated by the gateway to the client, also
internal services returns detailed errors with exported error codes.

This patch adds an initial round of detailed errors. They are not stable
and will change in future.
@sgotti sgotti force-pushed the gateway_api_errors branch from 110d6a0 to d2fc020 Compare April 18, 2024 13:30
@sgotti sgotti merged commit 20f80cd into agola-io:master Apr 18, 2024
1 check passed
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.

1 participant