我在Ubuntu的 2.2.0* 版本中使用 grails
已有一段时间,一切都进行得很好。我的申请运行正常。昨天我将JDK更新为1.7.0_25,我敢肯定那只是我所做的更改。从那时起,我的所有应用程序在调用run-
app时都会引发错误(底部的stacktrace)。
*
Could not determine Hibernate dialect for database name [H2]! # or PostgresSQL if postgres is used
我在一个项目上摆弄了webxml插件,但我认为这不会搞乱其他应用程序。我使用git进行版本控制,即使我返回稳定的提交,该错误仍然会出现。
有趣的是,如果我 从IntelliJ Idea中 运行该应用程序,它的 工作就像一个魅力 。但是我真的很想使用经典的命令行工具。
IntelliJ使用以下命令启动应用程序:
/usr/lib/jvm/java-7-oracle/bin/java -Dgrails.home=/usr/share/grails/2.2.0 -Dbase.dir=/home/freeman/Dokumenty/cms/plugins/Diagnostics -Dtools.jar=/usr/lib/jvm/java-7-oracle/lib/tools.jar -Dgroovy.starter.conf=/usr/share/grails/2.2.0/conf/groovy-starter.conf -Xmx512M -XX:MaxPermSize=192m -Didea.launcher.port=7533 -Didea.launcher.bin.path=/home/freeman/programy/idea-IU-117.798/bin -Dfile.encoding=UTF-8 -classpath /usr/share/grails/2.2.0/lib/org.codehaus.groovy/groovy-all/jars/groovy-all-2.0.5.jar:/usr/share/grails/2.2.0/dist/grails-bootstrap-2.2.0.jar:/home/freeman/programy/idea-IU-117.798/lib/idea_rt.jar com.intellij.rt.execution.application.AppMain org.codehaus.groovy.grails.cli.support.GrailsStarter --main org.codehaus.groovy.grails.cli.GrailsScriptRunner --conf /usr/share/grails/2.2.0/conf/groovy-starter.conf run-app
我也尝试删除〜/ .grails / 2.2.0 / projects / Diagnostics,但这没有帮助。
任何想法有什么问题吗?我很拼命。
谢谢你的帮助。
堆栈跟踪:
2013-06-25 11:19:59,754 [localhost-startStop-1] ERROR context.GrailsContextLoader - Error initializing Grails: Error creating bean with name 'transactionManagerPostProcessor': Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager': Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory': Cannot resolve reference to bean 'hibernateProperties' while setting bean property 'hibernateProperties'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateProperties': Cannot resolve reference to bean 'dialectDetector' while setting bean property 'properties' with key [hibernate.dialect]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
Message: Error creating bean with name 'transactionManagerPostProcessor': Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager': Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory': Cannot resolve reference to bean 'hibernateProperties' while setting bean property 'hibernateProperties'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateProperties': Cannot resolve reference to bean 'dialectDetector' while setting bean property 'properties' with key [hibernate.dialect]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
Line | Method
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
Caused by BeanCreationException: Error creating bean with name 'transactionManager': Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory': Cannot resolve reference to bean 'hibernateProperties' while setting bean property 'hibernateProperties'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateProperties': Cannot resolve reference to bean 'dialectDetector' while setting bean property 'properties' with key [hibernate.dialect]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
Caused by BeanCreationException: Error creating bean with name 'sessionFactory': Cannot resolve reference to bean 'hibernateProperties' while setting bean property 'hibernateProperties'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateProperties': Cannot resolve reference to bean 'dialectDetector' while setting bean property 'properties' with key [hibernate.dialect]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
Caused by BeanCreationException: Error creating bean with name 'hibernateProperties': Cannot resolve reference to bean 'dialectDetector' while setting bean property 'properties' with key [hibernate.dialect]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
Caused by BeanCreationException: Error creating bean with name 'dialectDetector': Invocation of init method failed; nested exception is org.codehaus.groovy.grails.orm.hibernate.exceptions.CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
Caused by CouldNotDetermineHibernateDialectException: Could not determine Hibernate dialect for database name [H2]!
->> 334 | innerRun in java.util.concurrent.FutureTask$Sync
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 166 | run in java.util.concurrent.FutureTask
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run in java.util.concurrent.ThreadPoolExecutor$Worker
^ 724 | run . . . in java.lang.Thread
这是由于1.7.0_25中的更改导致使用弹簧加载时出现问题。它已在Grails
2.2.3中修复,因此升级到该版本将解决此问题。参见http://jira.grails.org/browse/GRAILS-10183
我在Ubuntu上使用grails 2.2.0版有一段时间了,一切都很顺利。我的应用程序运行良好。昨天我将JDK更新为1.7.0_25,我确信这是我做的唯一更改。从那时起,所有我的应用程序在调用run应用程序时都会出错(底部的stacktrace)。 我在一个项目上摆弄了webxml插件,但我不认为这会搞砸其他应用程序。我使用git进行版本控制,即使我回到稳定提交,错误仍然会出现。 有趣的是,如果
我正在尝试使用NuoDB构建一个基于gorm的时髦项目。但是收到此错误 - 无法确定数据库名称 [NuoDB] 的Hibernate方言! 奇怪的是,它与mysql一起工作。因此,我最初的怀疑是NuoDB的数据库配置,但我检查并重新检查了配置参数,如这里提供的NuoDB文档所示 我还将grails-datastore-gorm-hibernate 4版本从1.1.0升级到3.1.1.RELEASE
问题内容: 运行时出现此错误: 执行引导程序时出错:创建名称为’messageSource’的bean时出错:初始化bean失败;嵌套的异常是org.springframework.beans.factory.BeanCreationException:创建名称为’transactionManager’的bean时出错:设置bean属性’sessionFactory’时无法解析对bean’sess
似乎“将tensorflow导入为tf”直接引发了此错误 Colab link:https://colab.research.google.com/drive/1Jr0j_I_npKQxcQ1ggJQFHTqoJHmt9Bqk
我正在用Hibernate和Websphere application Server 8.0开发一个应用程序。 我已经在Websphere中创建了一个数据源,它可以成功地与数据库连接。 但从应用程序我得到以下错误: 系统错误创建会话:org。冬眠服务jndi。JndiException:无法查找JNDI名称[java:comp/env/jdbc/OracleDS] 以下是我所做的设置: Websp
我得到一个错误,当我试图运行这个简单的脚本: 假设我输入“dude”,我得到的错误是: 我正在运行MacOSX10.9.1,我正在使用安装了Python3.3的PythonLauncher应用程序来运行脚本。