I have an error when I integrate JSF, Hibernate, and Spring. I have created some unit tests, and all of them work. I think that the problem is coming from JSF. I get this error:
failed; nested exc开发者_开发百科eption is java.lang.IllegalArgumentException: 'sessionFactory' or 'hibernateTemplate' is required
It has nothing to do with JSF. You're using Spring's HibernateDaoSupport, and you're not supplying it with either a Hibernate SessionFactory or a Spring HibernateTemplate. You must set one of those properties for a HibernateDaoSupport to work.
Take note that HibernateDaoSupport is considered legacy. If this is new development, you should be using the currently recommended way of using Hibernate from Spring.
精彩评论