zoukankan      html  css  js  c++  java
  • 启动异常tried to access method org.springframework.core.GenericTypeResolver.getTypeVariableMap

    在使用spring-data-jpa的发生异常

    Caused by: java.lang.IllegalAccessError: tried to access method org.springframework.core.GenericTypeResolver.getTypeVariableMap(Ljava/lang/Class;)Ljava/util/Map; from class org.springframework.data.util.ClassTypeInformation
    at org.springframework.data.util.ClassTypeInformation.<init>(ClassTypeInformation.java:96)
    at org.springframework.data.util.ClassTypeInformation.<clinit>(ClassTypeInformation.java:42)
    at org.springframework.data.repository.core.support.AbstractRepositoryMetadata.<init>(AbstractRepositoryMetadata.java:43)
    at org.springframework.data.repository.core.support.DefaultRepositoryMetadata.<init>(DefaultRepositoryMetadata.java:41)
    at org.springframework.data.repository.core.support.RepositoryFactorySupport.getRepositoryMetadata(RepositoryFactorySupport.java:154)
    at org.springframework.data.repository.core.support.RepositoryFactorySupport.getRepository(RepositoryFactorySupport.java:125)
    at org.springframework.data.repository.core.support.RepositoryFactoryBeanSupport.getObject(RepositoryFactoryBeanSupport.java:114)
    at org.springframework.data.repository.core.support.RepositoryFactoryBeanSupport.getObject(RepositoryFactoryBeanSupport.java:38)
    at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:142)
    ... 34 more

    原因是spring-data-jpa.jar的版本和spring-data-commons-core.jar的版本不匹配所造成的,spring-data-commons-core.jar的版本过高了.

    在发生异常的时候我的版本是:spring-data-jpa-1.0.2.RELEASE.jar和spring-data-commons-core-1.3.0.M1.jar

    更改后:spring-data-jpa-1.0.2.RELEASE.jar和spring-data-commons-core-1.1.0.RELEASE.jar (OK)

    由于这个错误我还遇到:

    java.lang.AbstractMethodError: org.springframework.data.jpa.repository.config.SimpleJpaRepositoryConfiguration.getRepositoryBaseInterface()Ljava/lang/Class;
    

      



  • 相关阅读:
    sql 生成javabean实体
    git 安装 使用过程遇到的问题
    CentOS7 ab压力测试安装
    Lvs+keepalived+mysql(主从复制)
    liunx下tomcat启动 Cannot find ./catalina.sh
    ftp和ssh登录缓慢的解决办法
    Contos7 FTP 安装步骤
    python生成100以内格式化的数
    Windows中更新python模块的命令
    scrapy的User-Agent中间件、代理IP中间件、cookies设置、多个爬虫自定义settings设置
  • 原文地址:https://www.cnblogs.com/coveted/p/2381757.html
Copyright © 2011-2022 走看看