查看/page.jsf无法还原 [英] View /page.jsf could not be restored
本文介绍了查看/page.jsf无法还原的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有无法解决的问题.当页面空闲(例如10分钟)后刷新打开的JSF页面时,出现以下错误消息:
I have problem which I cannot solve. When I refresh opened JSF page after the page is idle for example 10 minutes I get this error message:
serverError: class javax.faces.application.ViewExpiredException viewId:/page.jsf - View /page.jsf could not be restored.
如何增加JSF View时间?
How I can increase the JSF View time?
推荐答案
您可以像这样在web.xml中将会话超时参数设置为45分钟
You can set your session timeout parameter to 45 minute in web.xml like this
<session-config>
<session-timeout>45</session-timeout>
</session-config>
通过在web.xml中添加以下代码,您还可以在单独的页面中轻松处理此异常
also you can easily handle this exception in a seperate page by adding following code to your web.xml
<error-page>
<exception-type>javax.faces.application.ViewExpiredException</exception-type>
<location>/exception/sessionexpired.xhtml</location>
</error-page>
这篇关于查看/page.jsf无法还原的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文