【问题标题】:Hibernate dependencies, Cannot find scanner class休眠依赖项,找不到扫描仪类
【发布时间】:2019-08-12 00:54:33
【问题描述】:

在我的 pom.xml 中,我添加了以下依赖项:

    <dependency>
        <groupId>org.hibernate.common</groupId>
        <artifactId>hibernate-commons-annotations</artifactId>
        <version>4.0.1.Final</version>
    </dependency>

因为之前,在我的日志控制台中出现了同样的错误,java.lang.ClassNotFoundException: org.jboss.as.jpa.hibernate4.HibernateAnnotationScanner,然后我添加了 hibernate.anotations 依赖,但错误仍然存​​在,需要我另一个依赖来让它启动吗?

当我将persistence.xml 添加到我的项目时,这个问题就开始了。 我正在使用 Jboss EAP 6.1 服务器。

【问题讨论】:

    标签: hibernate jakarta-ee jboss persistence pom.xml


    【解决方案1】:

    已解决:

    我需要安装该依赖项的较新版本,添加核心依赖项并将 entitymanager 依赖项版本更改为与核心相同。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-12-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-10-26
      • 2011-12-03
      相关资源
      最近更新 更多