1. web.xml中别忘记加入spring监听器
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
2. 注意bean的id(datasource)和sessionfactory引入的datasource名字要完全相同
1. web.xml中别忘记加入spring监听器
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
2. 注意bean的id(datasource)和sessionfactory引入的datasource名字要完全相同
spring-springmvc-hibernate项目小结
原文:https://www.cnblogs.com/ggqzz/p/8421741.html