Reason: JSON library is not on your project's class path. I resolved this issue by adding following dependency in my project pom.xml file
<properties>
<jackson.version>2.2.3</jackson.version>
</properties>
<dependencies>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson.version}</version>
</dependency>
Once this library is on the classpath, your spring annotation-driven code will use it to return json responses instead of returning http 406
No comments:
Post a Comment