* Avoid `Decoder.decode` on 404 when void response type
Avoid calling `decode` when receiving a 404 error and `decode404` is set and the response type is `void`.
* Update CHANGELOG
* Add support for expansion of @Param lists
The existing support for expanders in method parameters is
limited to converting a single value. The change applies the
expander individually to each item in a collection or array,
thus making it useful for multi-valued query parameters, for
instance. The old behaviour is preserved because no existing
expanders would have been converting collections to strings
(probably).
* Change Collection to Iterable and add tests
* Add test for null conversion to empty string as well
* Remove array handling and null handling
OkHttp client should not bail out when response body is >2gb
Instead, we return null length and the response can be processed
similarly to a chunked body.
Also, shares common client tests in AbstractClientTest
Add @HeaderMap parameter annotation that allows
methods to have an annotated Map parameter whose
contents is used to set the header values on the
request. Provides a way for APIs to allow for
per-request header customization for both fields
and values without customizing the Feign client.
Before, instructions around form encoding were incomplete, particularly
around how to get a hold of a `Map<String, ?>` type. This exposes
`Encoder.MAP_STRING_WILDCARD` to make form encoding easier.
Closes#259
I mistakenly advised `@Headers` to follow the encoding rules of `@Body`.
This was a a mistake as in both cases, url encoding is a bad choice, if
the only goal is to prevent accidental variable expansion. For example,
url encoding interferes a lot with content, including messing with '+'
characters, such as exist in "Accept: application/vnd.github.v3+json"
This changes `@Headers` to only address the problem, which where a '{'
literal is desired in a header value. The solution offered here is to
simply repeat "{{" when you desire a '{' literal. For example, if your
header value needs to be literally "{{variable}}", you'd encode it as
"{{{{variable}}".
The impact of this change is limited to those who have already started
using v8.15, and a fast release will occur after merge to limit that.
See #326Fixes#345Closes#346
This supports runtime injection of Param.Expander. Implementing
contracts will assign `MethodMetadata.indexToExpander` using configured
values. When `MethodMetadata.indexToExpander` is unset, Feign has the
existing behavior, which is to newInstance each `indexToExpanderClass`.