用RestTemplate.getForObject()获取URL的JSON时,可能会遇到如题所示的报错信息。

我的问题在于:在非MVC的Project中使用RestTemplate.
简单的说,message converters是负责Java Object和Http上的JSON/XML互相转换的中介工具。Ref by baeldung.
如果是在非MVC的Project中,根本就不会产生HttpMessageConverter ,此时使用RestTemplate会报如题所示的错误。

在查资料的同时也发现一个解决该问题的文档,Could not extract response: no suitable HttpMessageConverter found for response type,它解决的是Http上的文件类型与Java Object类型不匹配的问题,如果有人查这个问题到我的博客页面,希望这个链接能为你节约一些时间。:)

Could not extract response: no suitable HttpMessageConverter found for response type ***相关推荐

  1. 小小涉及OpenFeign原理:Could not extract response: no suitable HttpMessageConverter found for response type

    一.问题解释(想看总结的去最下面) org.springframework.web.client.UnknownContentTypeException: Could not extract resp ...

  2. Could not extract response: no suitable HttpMessageConverter found for response type [class com.exam

    报错信息:Could not extract response: no suitable HttpMessageConverter found for response type [class com ...

  3. 使用RestTemplate:报错Could not extract response: no suitable HttpMessageConverter found for response typ

    项目中需要调用微信接口获取access_token等一系列和微信接口相关的操作,我使用了Spring自带的RestTemplate类来发送Get或Post请求,直接在Spring配置文件中依赖注入 & ...

  4. RestTemplate请求Could not extract response: no suitable HttpMessageConverter found for response type..

    使用 Spring Boot 写项目,需要用到微信接口获取用户信息. 在 Jessey 和 Spring RestTemplate 两个 Rest 客户端中,想到尽量不引入更多的东西,然后就选择了 S ...

  5. Could not extract response: no suitable HttpMessageConverter found for response type [class java.lan

    解决 Could not extract response: no suitable HttpMessageConverter found for response type [class java. ...

  6. Could not extract response: no suitable HttpMessageConverter found for content type [text/html]

    目录 报错信息 源码分析 解决方法 修改 mappingJackson2HttpMessageConverter 配置 继承 mappingJackson2HttpMessageConverter 实 ...

  7. openFeig远程调用报错Could not extract response: no suitable HttpMessageConverter found for response type

    解决方案:在调用服务和被调用的服务上都加上一个配置类 @Configuration public class jsonConfig {@Beanpublic HttpMessageConverters ...

  8. Could not extract response: no suitable HttpMessageConverter

    版本:spring-cloud-openfeign-core-2.1.1.RELEASE.jar,spring-webmvc-5.1.14.RELEASE.jar,jetty-server-9.4.4 ...

  9. 【feign】feign.codec.DecodeException: Could not extract response: no suitable HttpMessageConverter

    问题描述 在springboot 2的版本中通过feign进行调用,在引入私服jar包并进行调用时,报错: feign.codec.DecodeException: Could not extract ...

最新文章

  1. ylb:SQL 常用函数
  2. 跟vczh看实例学编译原理——一:Tinymoe的设计哲学
  3. 第一个SpringBoot入门级项目(超详细步骤)
  4. 小波的秘密6_小波包的理解
  5. Android Http POST文件上传之-----RFC1867协议
  6. 空之轨迹手游服务器维护,《空之轨迹》手游06月15日更新公告
  7. Unity3D之FSM有限状态机
  8. amend用法 git 信息_Git 高级用法,你用过哪些了
  9. 《结网》《人人都是产品经理》对比
  10. sakai 工具翻译——测试和测验1
  11. 最新的中国风歌曲——《颜如玉》
  12. microsoft office 文档左边导航窗格列表不见了
  13. “哥”不信“神马浮云”
  14. Nginx解决history模式下页面刷新404
  15. 游戏类型英文简称/全称对照表
  16. 请用python3编写一个计算器的控制台程序_二、软件工程慕课第一章作业题——编写一个计算器...
  17. java使用mybatis一次性插入多条数据
  18. 模拟cmos集成电路(4)
  19. 深度神经网络 英语,深度神经网络英文
  20. 《教务信息管理系统》项目总结

热门文章

  1. pythonic code_pythonic code_Pythonic Code (Part II)
  2. mysql查找出每个用户最新的一条订单的5种解决思路
  3. gensim 快速入门 Word2Vec
  4. storm drpc实例
  5. Light Field 光场
  6. 【题型总结】势能线段树
  7. 各数据库SQL查询结果多行数据合并成一行
  8. 推荐一个 Python 手绘图形库
  9. 秋梨膏的历史文化传承
  10. RecyclerView问题:java.lang.IndexOutOfBoundsException: Inconsistency detected. Invalid view holder adap