java.lang.ClassCastException: org.springframework.orm.hibernate4.SessionHolder cannot be cast to org.springframework.orm.hibernate3.SessionHolder

Spring JIRA | Augustine Parthinathan | 5 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.

    Root Cause Analysis

    1. java.lang.ClassCastException

      org.springframework.orm.hibernate4.SessionHolder cannot be cast to org.springframework.orm.hibernate3.SessionHolder

      at org.springframework.orm.hibernate3.SessionFactoryUtils.doGetSession()
    2. Hibernate
      HibernateTemplate.loadAll
      1. org.springframework.orm.hibernate3.SessionFactoryUtils.doGetSession(SessionFactoryUtils.java:287)
      2. org.springframework.orm.hibernate3.SessionFactoryUtils.getSession(SessionFactoryUtils.java:233)
      3. org.springframework.orm.hibernate3.HibernateTemplate.getSession(HibernateTemplate.java:457)
      4. org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:393)
      5. org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
      6. org.springframework.orm.hibernate3.HibernateTemplate.loadAll(HibernateTemplate.java:584)
      6 frames