I have been strugling against this for two days now, and finally reach a dead end.
Thing is, I'm handling a request like this:
public Mono<ServerResponse> jsonBodyDemo(ServerRequest request) {
request.bodyToMono(DemoDTO.class).log().subscribe(
d -> System.out.println(d.getName()),
e -> System.out.println("error"));
return ServerResponse.ok().body(BodyInserters.fromValue("OK"));
}
And the name is never logged. All I get is:
2020-04-29 14:46:39.210 INFO 20404 --- [ctor-http-nio-3] reactor.Mono.OnErrorResume.1 : onSubscribe(FluxOnErrorResume.ResumeSubscriber)
2020-04-29 14:46:39.210 INFO 20404 --- [ctor-http-nio-3] reactor.Mono.OnErrorResume.1 : request(unbounded)
But the actual onNext never happens
Any suggestion about what I'm missing?