Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SynchronousMethodHandler does not wrap exceptions thrown by Decoder#d…
…ecode in decode404 mode Removing exception wrapping adds flexibility to the interplay of Decoder and ErrorDecoder: A Decoder can now delegate to an ErrorDecoder and the original ErrorDecoder exception gets thrown rather than a Feign-specific DecodeException. An example use-case is a Jackson/Gson implementation of special 404-handling of Optional<Foo> methods: when the Feign client has decode404() enabled, then the Decoder is in charge of dispatching 404 to Optional#absent where applicable, or to a delegate ErrorDecoder otherwise; consistent exception handling requires that the exception produced by the ErrorDecoder does not wrapped.
- Loading branch information
Robert Fink
committed
Nov 3, 2015
1 parent
40b32ec
commit 544820c
Showing
3 changed files
with
28 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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