SSH 在中出现的could not initialize proxy - no Session 问题
来源:互联网 发布:淘宝官方网站登录网站 编辑:程序博客网 时间:2024/06/06 11:02
在SSH整合的过程中由于Spring容器管理所有的类,这样就会出现在service层调用dao层后其session就会关闭,这样当在jsp中用 ${requestScope.person.name} 获取数据时 由于session已经被关闭 所以会出现 could not initialize proxy - no Session 的问题
器解决方法是在web.xml 中加入
<filter>
<filter-name>OpenSessionInViewFilter</filter-name>
<filter-class>org.springframework.orm.hibernate3.support.OpenSessionInViewFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>OpenSessionInViewFilter</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
起到延迟session 关闭的作用这样页面就不会除草。
0 0
- SSH 在中出现的could not initialize proxy - no Session 问题
- ssh问题之:could not initialize proxy - no Session
- Hibernate3中could not initialize proxy - no Session的解决办法
- 【JAVA】【WEB】【SSH】could not initialize proxy-no Session
- could not initialize proxy - no Session 问题分析
- hibernate延迟加载问题-------could not initialize proxy - no Session
- SSH+DWR异常org.hibernate.LazyInitializationException: could not initialize proxy - no Session的解决办法
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- hibernate3中出现 could not initialize proxy - no Session 错误的解决办法以及lazy load的介绍
- C# 实验三 找出字符串中的有用信息
- Java基本数据类型
- 华为2015年校园招聘机试题(2)
- 【论文笔记】residual neural network-kaiming he
- Caused by: java.lang.NoSuchMethodError: ....SchedulerFactoryBean.getObject()Lorg/quartz/Scheduler
- SSH 在中出现的could not initialize proxy - no Session 问题
- Android 递归栈溢出问题解决
- 郑轻OJ zzulioj 1068: 二进制数
- android studio改变主题字体大小
- 奖券数目
- 前端优化建议
- Java 异常处理
- 项目经理面试中常被问到的12问题
- 【红宝书笔记】原型模式-prototype