当前位置: 代码迷 >> 综合 >> ClassNotFoundException: redis.clients.jedis.util.SafeEncoder NoClassDefFoundError......
  详细解决方案

ClassNotFoundException: redis.clients.jedis.util.SafeEncoder NoClassDefFoundError......

热度:37   发布时间:2023-11-24 02:45:36.0

具体报错信息:

Caused by: org.springframework.beans.BeanInstantiationException:
Failed to instantiate
[org.springframework.data.redis.connection.jedis.JedisConnectionFactory]:
Factory method ‘JedisConnectionFactory’ threw exception; nested
exception is java.lang.NoClassDefFoundError:
redis/clients/jedis/util/SafeEncoder

Caused by: java.lang.NoClassDefFoundError:
redis/clients/jedis/util/SafeEncoder

Caused by: java.lang.ClassNotFoundException:
redis.clients.jedis.util.SafeEncoder

原因:
网上有看到别人说可能是maven版本过高了,于是将原来maven3.6版本的替换为apache-maven-3.3.9,然后就不再报错了
在这里插入图片描述

  相关解决方案