前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >The calling method‘s class, org.redisson.spring.data.connection.RedissonConnection

The calling method‘s class, org.redisson.spring.data.connection.RedissonConnection

作者头像
MickyInvQ
发布2023-10-16 14:58:18
2880
发布2023-10-16 14:58:18
举报
文章被收录于专栏:InvQ的专栏InvQ的专栏
代码语言:javascript
复制
***************************
APPLICATION FAILED TO START
***************************

Description:

An attempt was made to call a method that does not exist. The attempt was made from the following location:

    org.redisson.spring.data.connection.RedissonConnection.<clinit>(RedissonConnection.java:1764)

The following method did not exist:

    org/redisson/client/protocol/RedisStrictCommand.<init>(Ljava/lang/String;Ljava/lang/String;Lorg/redisson/client/protocol/Decoder;)V

The calling method's class, org.redisson.spring.data.connection.RedissonConnection, was loaded from the following location:

    jar:file://.m2/repository/org/redisson/redisson-spring-data-22/3.12.3/redisson-spring-data-22-3.12.3.jar!/org/redisson/spring/data/connection/RedissonConnection.class

The called method's class, org.redisson.client.protocol.RedisStrictCommand, is available from the following locations:

    jar:file:/C://.m2/repository/org/redisson/redisson/3.17.6/redisson-3.17.6.jar!/org/redisson/client/protocol/RedisStrictCommand.class

The called method's class hierarchy was loaded from the following locations:

这个错误提示显示在 org.redisson.spring.data.connection.RedissonConnection 类的静态初始化块中调用了一个不存在的方法 org.redisson.client.protocol.RedisStrictCommand.(Ljava/lang/String;Ljava/lang/String;Lorg/redisson/client/protocol/Decoder;)V。

这个错误可能是由于 Redisson 的版本不兼容导致的。在 Redisson 3.17.6 中,RedisStrictCommand 类中存在该构造方法,但在 Redisson 3.12.3 中,该构造方法可能已经被删除或者改名了。

为了解决这个问题,您可以尝试以下步骤:

确认您的项目中使用的 Redisson 版本是否正确,并且与您的其他依赖项兼容。您可以在项目的 pom.xml 文件中确认 Redisson 的版本。

尝试升级 Redisson 版本到最新版本,或者将 Redisson 版本降级到与其他依赖项兼容的版本。

如果您使用的是 Spring Boot,可以尝试使用 Spring Boot 的依赖管理功能来管理 Redisson 依赖项的版本,例如:

代码语言:javascript
复制
  <dependencyManagement>
       <dependencies>
           <dependency>
               <groupId>org.redisson</groupId>
               <artifactId>redisson-spring-boot-starter</artifactId>
               <version>3.17.6</version>
           </dependency>
       </dependencies>
   </dependencyManagement>

这样可以确保 Redisson 依赖项的版本与 Spring Boot 的版本兼容。

在这里插入图片描述
在这里插入图片描述
本文参与 腾讯云自媒体分享计划,分享自作者个人站点/博客。
原始发表:2023-08-18,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档