问题
Spring web 与 Spring eureka集成后出现错误:

Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.fasterxml.jackson.databind.SerializationConfig
at com.fasterxml.jackson.databind.ObjectMapper.(ObjectMapper.java:560) ~[jackson-databind-2.8.9.jar:2.8.9]
at com.fasterxml.jackson.databind.ObjectMapper.(ObjectMapper.java:476) ~[jackson-databind-2.8.9.jar:2.8.9]
at org.springframework.http.converter.json.Jackson2ObjectMapperBuilder.build(Jackson2ObjectMapperBuilder.java:588) ~[spring-web-4.3.10.RELEASE.jar:4.3.10.RELEASE]
at org.springframework.http.converter.json.MappingJackson2HttpMessageConverter.(MappingJackson2HttpMessageConverter.java:57) ~[spring-web-4.3.10.RELEASE.jar:4.3.10.RELEASE]
at org.springframework.http.converter.support.AllEncompassingFormHttpMessageConverter.(AllEncompassingFormHttpMessageConverter.java:61) ~[spring-web-4.3.10.RELEASE.jar:4.3.10.RELEASE]
at org.springframework.web.filter.HttpPutFormContentFilter.(HttpPutFormContentFilter.java:63) ~[spring-web-4.3.10.RELEASE.jar:4.3.10.RELEASE]
at org.springframework.boot.web.filter.OrderedHttpPutFormContentFilter.(OrderedHttpPutFormContentFilter.java:29) ~[spring-boot-1.5.6.RELEASE.jar:1.5.6.RELEASE]
at org.springframework.boot.autoconfigure.web.WebMvcAutoConfiguration.httpPutFormContentFilter(WebMvcAutoConfiguration.java:149) ~[spring-boot-autoconfigure-1.5.6.RELEASE.jar:1.5.6.RELEASE]
at org.springframework.boot.autoconfigure.web.WebMvcAutoConfigurationEnhancerBySpringCGLIBEnhancerBySpringCGLIBEnhancerBySpringCGLIB362ebeb8.CGLIB$httpPutFormContentFilter1(<generated>)[spring−boot−autoconfigure−1.5.6.RELEASE.jar:1.5.6.RELEASE]atorg.springframework.boot.autoconfigure.web.WebMvcAutoConfiguration1(<generated>) ~[spring-boot-autoconfigure-1.5.6.RELEASE.jar:1.5.6.RELEASE] at org.springframework.boot.autoconfigure.web.WebMvcAutoConfiguration1(<generated>) [spring−boot−autoconfigure−1.5.6.RELEASE.jar:1.5.6.RELEASE]atorg.springframework.boot.autoconfigure.web.WebMvcAutoConfigurationEnhancerBySpringCGLIBEnhancerBySpringCGLIBEnhancerBySpringCGLIB362ebeb8362ebeb8362ebeb8FastClassBySpringCGLIBFastClassBySpringCGLIBFastClassBySpringCGLIB95d8aacd.invoke(<generated>)[spring−boot−autoconfigure−1.5.6.RELEASE.jar:1.5.6.RELEASE]atorg.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)[spring−core−4.3.10.RELEASE.jar:4.3.10.RELEASE]atorg.springframework.context.annotation.ConfigurationClassEnhancer95d8aacd.invoke(<generated>) ~[spring-boot-autoconfigure-1.5.6.RELEASE.jar:1.5.6.RELEASE] at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228) ~[spring-core-4.3.10.RELEASE.jar:4.3.10.RELEASE] at org.springframework.context.annotation.ConfigurationClassEnhancer95d8aacd.invoke(<generated>) [spring−boot−autoconfigure−1.5.6.RELEASE.jar:1.5.6.RELEASE]atorg.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228) [spring−core−4.3.10.RELEASE.jar:4.3.10.RELEASE]atorg.springframework.context.annotation.ConfigurationClassEnhancerBeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:358) ~[spring-context-4.3.10.RELEASE.jar:4.3.10.RELEASE]
at org.springframework.boot.autoconfigure.web.WebMvcAutoConfigurationEnhancerBySpringCGLIBEnhancerBySpringCGLIBEnhancerBySpringCGLIB362ebeb8.httpPutFormContentFilter() ~[spring-boot-autoconfigure-1.5.6.RELEASE.jar:1.5.6.RELEASE]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_144]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_144]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_144]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_144]
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162) ~[spring-beans-4.3.10.RELEASE.jar:4.3.10.RELEASE]
… 27 common frames omitted

pom.xml:

org.springframework.boot spring-boot-starter-web 1.5.6-RELEASE org.springframework.cloud spring-cloud-starter-eureka 1.2.7-RELEASE

解决方案
pom文件指定

jackson-databind
具体版本:

com.fasterxml.jackson.core jackson-databind 2.8.9

原文链接:http://www.xszf.net/game/

Could not initialize class com.fasterxml.jackson相关推荐

  1. NoClassDefFoundError: Could not initialize class com.fasterxml.jackson.databind.ObjectMapper

    <!-- 解决构建失败问题 --><dependency><groupId>com.fasterxml.jackson.core</groupId>&l ...

  2. 【安全漏洞】jackson-databind漏洞、 异常NoClassDefFoundError: Could not initialize class com.fasterxml.jackson

    一.jackson-databind漏洞 https://blog.csdn.net/kzadmxz/article/details/97191101

  3. com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'user'

    nested exception is com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'user' 可能错误原因: ...

  4. JsonUtils fasterxml jackson

    2019独角兽企业重金招聘Python工程师标准>>> package com.dominos.cloud.common.util;import java.io.IOExceptio ...

  5. com.fasterxml.jackson.databind.JsonMappingException: Multiple back-reference properties with name ‘d

    今天在写SpringBoot + JPA的时候报了以下的错误 com.fasterxml.jackson.databind.JsonMappingException: Multiple back-re ...

  6. java运行报错NoClassDefFoundError: com/fasterxml/jackson/databind/JsonNode的解决方案

    引入如下依赖即可: <dependency><groupId>com.fasterxml.jackson.core</groupId><artifactId& ...

  7. springboot加入com.fasterxml.jackson.core-jackson-databind依赖后报错Error creating bean with name ‘requestM

    springboot在pom.xml中加入依赖com.fasterxml.jackson.core-jackson-databind后报错,报错如下:Error creating bean with ...

  8. java.lang.ClassNotFoundException: com.fasterxml.jackson.databind.exc.InvalidDefinitionException

    在引入Jacksonjar包时,运行程序抛出了这个异常: java.lang.ClassNotFoundException: com.fasterxml.jackson.databind.exc.In ...

  9. com.fasterxml.jackson将对象序列化成json时,出现在json里的属性名称是怎么来的

    如果不考虑用任何annotation指定出现在json string里的属性名称的话,默认的逻辑是将getter方法里,"get"之后的字符串的首字母小写. 比如: getJerD ...

最新文章

  1. hadoop商品推荐_百战卓越班学员学习经验分享:商品推荐
  2. 让Maven项目使用Nexus作为远程仓库的settings.xml配置
  3. oracle11g导出表时会发现少表,空表导不出解决方案。
  4. LeetCode44 Wildcard Matching
  5. 10.2.1 CSS介绍与引入
  6. C++基本数据类型解惑
  7. Oracle结构设计技巧(访问数据库象访问内存一样 快)
  8. 使用t-sql语句修改表中的某些数据及数据类型。_数据库基本理论详细介绍
  9. LeetCode 24. 两两交换链表中的节点(递归+循环)
  10. [Ahoi2013]连通图
  11. php基础自测卷2,php基础2
  12. 改变多目标跟踪领域!CMU等推出大规模多类别MOT数据集TAO
  13. python时间函数详解_Python 日期的转换及计算的具体使用详解
  14. centos7忘记root密码重置
  15. TF-tf.keras.layers.Attention-Attention机制
  16. 架构之美第八章-软件架构的含义
  17. 南京周边城市两日游方案
  18. 摄像头采集图像本地HDMI输出延迟测试
  19. 印光大师、净空法师:法师、居士示现神通需注意哪些事项?
  20. 【STL切片算法文献笔记】基于GPU并行计算的3D打印切片算法

热门文章

  1. OSG使用OpenGL(以及glad库)绘制自定义图形
  2. 【屏幕模块 - 笔记】深圳市晶联讯电子 液晶模块 JLX19296G-915-BN
  3. jsp层级选择器_jQuery 选择器
  4. 三大视角,聊聊我眼中的广告系统
  5. python+opencv实现文字颜色识别与标定
  6. 多路PT100转RS485模块
  7. 老程序员教你如何提高开发效率、成为大神4——快速学习方法
  8. oracle 查询本年12月,Oracle查询1-12月数据
  9. JavaScript中查找关键词
  10. sqlite3, IntegrityError: UNIQUE constraint failed when inserting a value