I\'m using a spring-webflux WebClient (build 20170502.221452-172) to access a Web application producing a stream of Entry objects (application/stream+json) like th
Based on the replies above, I ended up with this code:
final ObjectMapper mapper = new ObjectMapper()
.findAndRegisterModules()
.enable(DeserializationFeature.ACCEPT_EMPTY_STRING_AS_NULL_OBJECT);
final ExchangeStrategies exchangeStrategies = ExchangeStrategies.builder()
.codecs(configurer -> configurer.defaultCodecs()
.jackson2JsonDecoder(new Jackson2JsonDecoder(mapper)))
.build();
final WebClient webClient = WebClient.builder()
.exchangeStrategies(exchangeStrategies)
.build();
If you don't include .findAndRegisterModules(), you're going to have problems when you want to deserialise things like Java 8's time objects.