Support non-Object types for WebFlux requests
* Add the support for a `Publisher`, `Resource` and `MultiValueMap` into the `WebFluxRequestExecutingMessageHandler` * Along side with the `WebFluxRequestExecutingMessageHandler.setPublisherElementType` and `WebFluxRequestExecutingMessageHandler.setPublisherElementTypeExpression`, add XSD support for the `publisher-element-type(-expression)`, which is used for the element type when request body is a `Publisher` * Polishing for `AbstractHttpRequestExecutingMessageHandler` * Fix Sonar smells for affected classes * Remove used imports Doc polishing
This commit is contained in:
committed by
Gary Russell
parent
24304ef4d4
commit
f8f69c9129
@@ -138,6 +138,11 @@ In addition a `BodyExtractor<?, ClientHttpResponse>` can be injected into the `W
|
||||
It can be used for low-level access to the `ClientHttpResponse` and more control over body and HTTP headers conversion.
|
||||
Spring Integration provides `ClientHttpResponseBodyExtractor` as a identity function to produce (downstream) the whole `ClientHttpResponse` and any other possible custom logic.
|
||||
|
||||
Starting with version 5.2, the `WebFluxRequestExecutingMessageHandler` supports reactive `Publisher`, `Resource`, and `MultiValueMap` types as the request message payload.
|
||||
A respective `BodyInserter` is used internally to be populated into the `WebClient.RequestBodySpec`.
|
||||
When the payload is a reactive `Publisher`, a configured `publisherElementType` or `publisherElementTypeExpression` can be used to determine a type for the publisher's element type.
|
||||
The expression must be resolved to a `Class<?>`, `String` which is resolved to the target `Class<?>` or `ParameterizedTypeReference`.
|
||||
|
||||
See <<http-outbound>> for more possible configuration options.
|
||||
|
||||
[[webflux-namespace]]
|
||||
|
||||
@@ -60,3 +60,9 @@ See <<note-nio>> for more information.
|
||||
|
||||
The `AbstractMailReceiver` has now an `autoCloseFolder` option (`true` by default), to disable an automatic folder close after a fetch, but populate `IntegrationMessageHeaderAccessor.CLOSEABLE_RESOURCE` header instead for downstream interaction.
|
||||
See <<mail-inbound>> for more information.
|
||||
|
||||
[[x5.2-webflux]]
|
||||
==== WebFlux Changes
|
||||
|
||||
The `WebFluxRequestExecutingMessageHandler` now supports a `Publisher`, `Resource` and `MultiValueMap` as a request message `payload`.
|
||||
See <<webflux>> for more information.
|
||||
|
||||
Reference in New Issue
Block a user