I get an error when I want to import my project to sts(eclipse). I generate this project with spring roo and its work an other laptop so I just want to import and run on tomcat server somebody know what is this, I watch the dependecies and this class is there (I use Windows):
当我想将项目导入到sts(eclipse)时,我收到错误。我使用spring roo生成这个项目,并且它的工作是另一台笔记本电脑,所以我只想导入并在tomcat服务器上运行,有人知道这是什么,我看了dependecies,这个类就在那里(我使用Windows):
2012-10-16 23:32:42,540 [main] ERROR org.springframework.web.context.ContextLoader - Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in file [D:\projects.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\roo-jquery-bootstrap\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in file [D:\projects.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\roo-jquery-bootstrap\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: Cannot find class [org.hibernate.ejb.HibernatePersistence] at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328) at
2012-10-16 23:32:42,540 [main]错误org.springframework.web.context.ContextLoader - 上下文初始化失败org.springframework.beans.factory.BeanCreationException:创建文件[D中定义的名称为'transactionManager'的bean时出错:\ projects.metadata.plugins \ org.eclipse.wst.server.core \ tmp0 \ wtpwebapps \ roo-jquery-bootstrap \ WEB-INF \ classes \ META-INF \ spring \ applicationContext.xml]:无法解析对bean的引用设置bean属性'entityManagerFactory'时'entityManagerFactory';嵌套异常是org.springframework.beans.factory.BeanCreationException:在文件[D:\ projects.metadata.plugins \ org.eclipse.wst.server.core \ tmp0 \ wtpwebapps \ roo-中定义的名称为'entityManagerFactory'的bean创建时出错jquery-bootstrap \ WEB-INF \ classes \ META-INF \ spring \ applicationContext.xml]:调用init方法失败;嵌套异常是java.lang.IllegalArgumentException:在org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)中找不到类[org.hibernate.ejb.HibernatePersistence]
... 41 more
......还有41个
1 个解决方案
#1
0
I solved that it was an eclipse bug i restarted the eclipse and the application worked..
我解决了这是一个日食错误我重新启动了日食和应用程序工作..
#1
0
I solved that it was an eclipse bug i restarted the eclipse and the application worked..
我解决了这是一个日食错误我重新启动了日食和应用程序工作..