通过feign远程访问微服务接口,调用出错

Blade 未结 2 1065

一、该问题的重现步骤是什么?

1. 

2. 

3.


二、你期待的结果是什么?实际看到的又是什么?

期望接口正常返回结果


实际错误信息如下:

92 ERROR 18796 --- [blade-system-14] o.s.core.cloud.feign.BladeFeignFallback  : BladeFeignFallback:[org.springblade.system.feign.Client.list] serviceId:[blade-system] message:[Error while extracting response for type [org.springblade.core.tool.api.R<java.util.List<org.springblade.system.vo.StuVO>>] and content type [application/json;charset=UTF-8]; nested exception is org.springframework.http.converter.HttpMessageNotReadableException: JSON parse error: Cannot deserialize instance of `java.util.ArrayList<org.springblade.system.vo.StuVO>` out of START_OBJECT token; nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot deserialize instance of `java.util.ArrayList<org.springblade.system.vo.StuVO>` out of START_OBJECT token

 at [Source: (PushbackInputStream); line: 1, column: 36] (through reference chain: org.springblade.core.tool.api.R["data"])]


三、你正在使用的是什么产品,什么版本?在什么操作系统上?

blade2.7.0

四、请提供详细的错误堆栈信息,这很重要。


五、若有更多详细信息,请在下面提供。

2条回答
  • 看报错是请求参数和接收的格式不一致导致的。

    0 讨论(0)
  • 2021-06-09 21:40

    尝试如下配置,看看是否有用

    #blade配置
    blade:
     #jackson配置
     jackson:
       #null自动转空值
       null-to-empty: false



    0 讨论(0)
提交回复