16. nested exception is com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "auditUnitName"
org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver:handleHttpMessageNotReadable:384 -Failed to read HTTP message: org.springframework.http.converter.HttpMessageNotReadableException: Could not read document: Unrecognized field "auditUnitName" (class com.ylkj.business.auditresult.problem.pojo.dto.ProblemSaveDto), not marked as ignorable (40 known properties: "problemNo", "rectifyperiodEnd", "amountOfPreviousYear", "projectName", "isCarryOver", "institutionProblem", "rectifyperiodStart", "isReportDisclosure", "area", "itemId", "problemNoGw", "requestCompleteTime", "problemAmount", "oneLevelType", "rectifyState", "responsibleUnit", "auditedUnit", "threeLevelType", "checkType", "auditOpinion", "responsiblePerson", "policyBasis", "twoLevelType", "itemTreeLevel", "importance", "currentYearInvolvedAmount", "definitionOfResponsibility", "problemType", "matterId", "year", "isIncludeFormalOpinions", "violationReason", "professionClassify", "isDistribute", "violationNature", "questionDate", "manageReason", "manageUnit", "isRemainProblem", "remainYear"])
at [Source: java.io.PushbackInputStream@7c1c7412; line: 1, column: 936] (through reference chain: com.ylkj.business.auditresult.problem.pojo.dto.ProblemSaveDto["auditUnitName"]); nested exception is com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "auditUnitName" (class com.ylkj.business.auditresult.problem.pojo.dto.ProblemSaveDto), not marked as ignorable (40 known properties: "problemNo", "rectifyperiodEnd", "amountOfPreviousYear", "projectName", "isCarryOver", "institutionProblem", "rectifyperiodStart", "isReportDisclosure", "area", "itemId", "problemNoGw", "requestCompleteTime", "problemAmount", "oneLevelType", "rectifyState", "responsibleUnit", "auditedUnit", "threeLevelType", "checkType", "auditOpinion", "responsiblePerson", "policyBasis", "twoLevelType", "itemTreeLevel", "importance", "currentYearInvolvedAmount", "definitionOfResponsibility", "problemType", "matterId", "year", "isIncludeFormalOpinions", "violationReason", "professionClassify", "isDistribute", "violationNature", "questionDate", "manageReason", "manageUnit", "isRemainProblem", "remainYear"])
at [Source: java.io.PushbackInputStream@7c1c7412; line: 1, column: 936] (through reference chain: com.ylkj.business.auditresult.problem.pojo.dto.ProblemSaveDto["auditUnitName"])
解决方案如下:
在需要转化的对象的类中添加注解,注解信息如下:
@JsonIgnoreProperties(ignoreUnknown = true)
16. nested exception is com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "auditUnitName"的更多相关文章
- com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field 异常
分享牛原创(尊重原创 转载对的时候第一行请注明,转载出处来自分享牛http://blog.csdn.net/qq_30739519) 1.1.1. 前言 近期在使用ObjectMapper对象将jso ...
- com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "ExceptionId"
com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "Exception ...
- com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "FileSize"
请求阿里云的OSS接口图片信息,返回json格式的数据,通过ObjectMapper将json转为Image对象时候报错转换失败 将json转对象的代码: String jsonStr = " ...
- Jackson反序列化错误:com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field的解决方法
说明:出现这种问题的情况是由于JSON里面包含了实体没有的字段导致反序列化失败. 解决方法: // 第一种解决方案 // ObjectMapper对象添加 mapper.configure(Deser ...
- JSON parse error: Cannot deserialize instance of `int` out of START_OBJECT token; nested exception is com.fasterxml.jackson.databind.exc
代码程序: @PostMapping("selectById") @ResponseBody public Result selectById(@RequestBody int i ...
- jackson json转实体对象 com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException
Jackson反序列化错误:com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field的解 ...
- JSON parse error: Can not deserialize instance of java.lang.String out of START_OBJECT token; nested exception is com.fasterxml.jackson.databind.JsonMappingException: Can not deserialize instance of j
异常信息如下: JSON parse error: Can not deserialize instance of java.lang.String out of START_OBJECT token ...
- HttpMessageNotWritableException: Could not write JSON: Infinite recursion (StackOverflowError); nested exception is com.fasterxml.jackson.databind.JsonMappingException: Infinite
org.springframework.http.converter.HttpMessageNotWritableException: Could not write JSON: Infinite r ...
- jackson json转实体 com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException
jackson 2.2.2 由于vo中缺少json的某个字段属性引起 2种解决方法 1:vo中添加注解@JsonIgnoreProperties(ignoreUnknown = true) 2. m ...
随机推荐
- 没有admin权限如何免安装使用Node和NPM
此教程只针对于在windows系统上没有admin权限和软件安装权限,但是又希望能像安装版一样使用Node和NPM的用户. 步骤一: 下载压缩版node 访问https://nodejs.org/en ...
- TF Notes (5), GRU in Tensorflow
小筆記. Tensorflow 裡實作的 GRU 跟 Colah's blog 描述的 GRU 有些不太一樣. 所以做了一下 TF 的 GRU 結構. 圖比較醜, 我盡力了- XD TF 的 GRU ...
- 【WPF学习】第五十一章 动画缓动
线性动画的一个缺点是,它通常让人觉得很机械且不能够自然.相比而言,高级的用户界面具有模拟真实世界系统的动画效果.例如,可能使用具有触觉的下压按钮,当单击时按钮快速弹回,但是当没有进行操作时它们会慢慢地 ...
- 02ARM体系结构
1.哈佛结构和冯式结构 8086: 冯氏结构 相同存储RAM相同的通道 统一编址 区别:运行态与存储态 STM32F103:哈弗结构 不同的存储不同的通道 统一编址 8051: 改进型的哈弗结构 不 ...
- Javascript学习笔记-基本概念-数据类型
1.typeof 操作符的返回值: "undefined"——如果这个值未定义: "boolean"——如果这个值是布尔值: "string" ...
- 用table类型布局一个新闻网页
<html><head><meta http-equiv="Content-Type" content="text/html; charse ...
- Python基础-两个乒乓球队进行比赛,各出三人。
两个乒乓球队进行比赛,各出三人.甲队为a,b,c三人,乙队为x,y,z三人.已抽签决定比赛名单.有人向队员打听比赛的名单.a说他不和x比,c说他不和x,z比,请编程序找出三队赛手的名单. L1 = [ ...
- 如何提升.NET控制台应用体验?
原文:Upgrade Your .NET Console App Experience 作者:Khalid Abuhakmeh 译文:Lamond Lu 在.NET生态系统中,控制台程序的表现相对较差 ...
- 以正确的方式下载和配置 ASP.NET Core 官方源码
我们可以在Github上面直接查看ASP.NET Core 3.x的源代码,但是我们也可以把源代码下载下来进行查看. 而下载源代码进行查看有很多好处: 任意的导航源代码 内置了一个示例项目 直接调试源 ...
- Linux环境下安装MySQL 5.7.28
先进入MySQL官网: www.mysql.com 去下载安装包 进入DOWNLOADS选项,点击MySQL Community (GPL) Downloads. 点击进入MySQL Communit ...