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

Stop supporting user-defined error decoders #80

Open
whickman opened this issue Feb 12, 2020 · 1 comment
Open

Stop supporting user-defined error decoders #80

whickman opened this issue Feb 12, 2020 · 1 comment

Comments

@whickman
Copy link
Contributor

What happened?

Custom error decoders are able to arbitrarily modify request and response bodies. This produces a huge API surface and a huge potential spread of client behavior. We should remove this ability and become opinionated about error handling.

This blocks moving retry behavior into middleware before error decoding, as retry behavior depends on whether or not an error was returned.

Ideally, we would also remove the WithDisableRestErrors functionality, although that will require more work.

What did you want to happen?

Users should not be able to define custom decoders.

@whickman
Copy link
Contributor Author

I think we will probably want to move retry logic down and just inform consumers that there's been an API break and their error decoders will no longer trigger retries... This unblocks correct retrying functionality.

It is still useful to get rid of this, though

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

No branches or pull requests

1 participant