The request sent by the client was syntactically incorrect
2016-08-12 15:05
537 查看
使用HttpUtil的doPostHttp方法发送请求时,收到了tomcat返回的以下错误信息:The request sent by the client was syntactically incorrect,debug了下发现发现tomcat返回了400错误:由于语法格式有误,服务器无法理解此请求
查找了下发现问题出在SpringMVC的@RequestBody注解上,该位置会将发送http post请求传送的json字符串转换成RequestBody注解的某个对象,但是post请求时传送的map缺失某些字段导致转换失败而返回400错误
将这个问题记录下来,希望能够帮助需要的朋友
查找了下发现问题出在SpringMVC的@RequestBody注解上,该位置会将发送http post请求传送的json字符串转换成RequestBody注解的某个对象,但是post请求时传送的map缺失某些字段导致转换失败而返回400错误
将这个问题记录下来,希望能够帮助需要的朋友
相关文章推荐
- The request sent by the client was syntactically incorrect.
- 又见The request sent by the client was syntactically incorrect ()
- 解决SpringMVC入参出现The request sent by the client was syntactically incorrect请求语法错误方法
- The request sent by the client was syntactically incorrect ()问题
- spring MVC 错误The request sent by the client was syntactically incorrect ()的解决
- The request sent by the client was syntactically incorrect.
- HTTP Status 400 - description:The request sent by the client was syntactically incorrect.
- spring mvc 数据绑定问题 提交表单提示HTTP status 400, The request sent by the client was syntactically incorrect
- spring mvc 数据绑定问题 提交表单提示HTTP status 400, The request sent by the client was syntactically incorrect
- The request sent by the client was syntactically incorrect ().问题排查
- springmvc提交表单,格式问题:The request sent by the client was syntactically incorrect.
- Springmvc注解开发:日期类型参数封装报错:The request sent by the client was syntactically incorrect.
- Spring MVC "The request sent by the client was syntactically incorrect ()"解决办法
- 错误:The request sent by the client was syntactically incorrect的解决
- The request sent by the client was syntactically incorrect.
- Http 400 --- The request sent by the client was syntactically incorrect
- Spring MVC "The request sent by the client was syntactically incorrect ()"解决办法
- The request sent by the client was syntactically incorrect
- spring mvc 400,The request sent by the client was syntactically incorrect的问题
- javaweb项目错误400-The request sent by the client was syntactically incorrect.