0

for my Portlet(*) I'm getting "ViewExpiredException"s although my session-timeout in ROOT/WEB-INF/web.xml is set with 600 (minutes).

The (portletapp)/WEB-INF/web.xml has no session-timeout configured.

Also there is no configuration like

session.timeout=30

in a portal.properties like mentioned in https://www.liferay.com/de/community/wiki/-/wiki/Main/Session+Timeout

Regarding the exception I'm currently planning to set

<context-param>
    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
    <param-value>client</param-value>
</context-param>

But I'd like to understand the problem. Where can I find other session-timeout configurations, or is this a default I need to overwrite?

Regards, Gunnar

(*) Liferay 6.2 EE SP10 on Tomcat 7.0.42, Mojarra 2.1.29, Portlet 2.0, Servlet 2.5, jstl 1.2.1, facelets 1.1.15, Primefaces 5.0

Update: Maybe I found the solution after more searching: Default session timeout for Apache Tomcat applications

(Tomcat's default session timeout in conf/web.xml)

Update: Problem not solved, own answer deleted. I just got the "ViewExpiredException" again.

I added debug logging of

"maxInactiveInterval: " + PortalUtil.getHttpServletRequest(((PortletRequest)FacesUtil.getExternalContext().getRequest())).getSession().getMaxInactiveInterval()

and I see my 600 configured minutes as 36000 seconds.

Any hints why I keep getting "ViewExpiredException"s?

My next try will be the portal.properties-entry mentioned above.

Community
  • 1
  • 1
Gunnar
  • 383
  • 4
  • 18
  • 1
    Causes of `ViewExpiredException` are clearly explained here: http://stackoverflow.com/questions/3642919/javax-faces-application-viewexpiredexception-view-could-not-be-restored As to your case, that Facelets 1.x library mixed in a JSF 2.x application certainly doesn't look good. Get rid of it. It would have a lot of undesired side effects. – BalusC Nov 13 '15 at 16:08
  • Thank you, BalusC. I've commented that Maven dependency out. In case this solves the problem, I'll give you feedback here so you can post it as an answer. – Gunnar Nov 16 '15 at 09:16
  • Looks like this erroneous dependency was responsible for this problem. I've left a browser instance alone for some hours and then clicked an ajax link in my portlet: No ViewExpiredException. Thanks again and cheers! – Gunnar Dec 01 '15 at 11:01

0 Answers0