I need a specific feature of hibernate that is StatelessSession and for that I need Hibernate\'s SessionFactory. The problem is I only have the entityManagerFactory. How can I g
Try to cast EntityManagerFactory to HibernateEntityManagerFactory.
EntityManagerFactory
Since EntityManagerFactory doesn't support unwrap() (unlike EntityManager), it seems to be the only way to achieve your goal.
unwrap()
EntityManager