Grails envers和hibernate插件不兼容
我正在使用hibernate插件并尝试将envers插件集成到我的项目中。但出现了以下问题: 当我试图启动项目时,它会给我一个例外:Grails envers和hibernate插件不兼容,grails,gorm,grails-2.0,grails-plugin,Grails,Gorm,Grails 2.0,Grails Plugin,我正在使用hibernate插件并尝试将envers插件集成到我的项目中。但出现了以下问题: 当我试图启动项目时,它会给我一个例外: [groovyc] org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: [groovyc] General error during conversion: java.lang.NoClassDefFoundError: org/hibernate/
[groovyc] org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
[groovyc] General error during conversion: java.lang.NoClassDefFoundError: org/hibernate/event/PostInsertEventListener
我的构建配置如下所示:
{
plugins {
// plugins for the build system only
build ":tomcat:7.0.54"
// plugins for the compile step
compile ":scaffolding:2.1.2"
compile ':cache:1.1.7'
compile ":asset-pipeline:1.8.11"
compile ":spring-security-ui:1.0-RC2"
// plugins needed at runtime but not for compilation
runtime ":hibernate4:4.3.5.4" // or ":hibernate:3.6.10.16"
runtime ":envers:2.1.0"
runtime ":database-migration:1.4.0"
runtime ":jquery:1.11.1"
}
我试图找到
PostInsertEventListener
类,但在不同的包下找到了它-在org.hibernate.event.spi
下,出于某种原因,它试图在org/hibernate/event
下找到它。这是一些插件不兼容的问题吗?谢谢大家! 运行grails依赖关系报告
查看冲突
您还可以尝试将
hib4
插件替换为hib3
。这很可能是导致编译错误的原因我已经尝试过了,但envers似乎不支持hib4,所以您有了解决方案