cannot import org.hibernate.session

前提是你 提交于 2019-12-08 09:40:05

问题


I installed wildfly 8.1 to my eclipse and wanted to move my old project from jboss 4.2 to new one. There is a problem that import org.hibernate.Session; cannot be resolwed on WildFly 8. can someone suggest any possible solutions?


回答1:


WildFly class loading is different comparing to JBoss 4.2. If you want to use Hibernate, than you'll need an explicit dependency on org.hibernate module.

One way of defining this is via a Dependencies entry in MAINFEST.MF:

Manifest-Version: 1.0
...
Dependencies: org.hibernate

Related reference section can be found here.



来源:https://stackoverflow.com/questions/24184992/cannot-import-org-hibernate-session

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!