1
votes

As I am trying to update spring-webflux dependency from spring-boot-starter-webflux in maven. My working code start giving error like"

From :

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-webflux</artifactId>
    <version>2.2.6.RELEASE</version>
</dependency>

changed to:

<dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-webflux</artifactId>
    <version>5.2.6.RELEASE</version>
</dependency>

Getting below Error:

org.springframework.web.reactive.function.UnsupportedMediaTypeException: Content type 'application/json' not supported for bodyType=com.location.of.Object at org.springframework.web.reactive.function.BodyInserters.unsupportedError(BodyInserters.java:391)

Note : I am trying Jackson library for POJO and having constructor in that. What could be issue? How to solve it?

1
@123 I tried this solution. I am trying Jackson library for POJO and having constructor in that. but it is not working. - nitin

1 Answers

0
votes

It is because of missing Jeckson dependency which I have't included in my project's submodule. I added the dependency in child module and it worked. Thanks all.