问题:在springmvc中添加Jackson jar包返回Object类型,处理器方法的produces属性不写,默认根据类型,但如果指定了(错误原因)produces = "text/html;charset=utf-8"就会报错

错误码: Handler execution resulted in exception: Could not find acceptable representation

正确配置:

@RequestMapping(value = "/jacksonMap.do", produces = "application/json;charset=utf-8")

 

 

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-06-27
  • 2022-12-23
  • 2021-12-17
  • 2022-01-15
  • 2022-12-23
  • 2021-06-30
猜你喜欢
  • 2022-12-23
  • 2022-01-29
  • 2021-04-08
  • 2021-10-27
  • 2022-12-23
相关资源
相似解决方案