HttpMessageNotReadableException(一)

1、今天移动端调用接口时候出现下面异常

org.springframework.http.converter.HttpMessageNotReadableException:

JSON parse error: Unrecognized token 'name': was expecting ('true', 'false' or 'null');

nested exception is com.fasterxml.jackson.core.JsonParseException:

Unrecognized token 'name': was expecting ('true', 'false' or 'null')

2、原因:

接口中要求json形式,name是String类型

前端传值为的是表单类型,出现了上面的错误

posted @ 2018-08-22 22:29  帅LOVE俊  阅读(35575)  评论(1编辑  收藏  举报