-
FEATURED COMPONENTS
First time here? Check out the FAQ!
In our system, we have encountered a problem where the timeout occurs randomly. It does not depend on what I am doing in my system, the system times out. That is, server side session is running but at client side, the message appears where it is written as - "Your session has expired." and it is redirected to the login page. Session timeout has been configured in web.xml as 30 minutes. Many times it displays this alert after just 5 seconds of login. There is no code in the system that explicitly fires logout.
For reference, configuration in zk.xml is mentioned below.
<session-config> <device-type>ajax</device-type> <session-timeout>0</session-timeout> <max-desktops-per-session>15</max-desktops-per-session> <max-requests-per-session>5</max-requests-per-session> <automatic-timeout>true</automatic-timeout> <timeout-uri>/Login.zul?r=1</timeout-uri> <timer-keep-alive>true</timer-keep-alive> </session-config>
Hello deepp1990,
Based on the provided configuration i made some tests using tomcat 7 and the session works as expected.
At the following url it dictates that the Default 0 (is dependant on the Web server).
http://books.zkoss.org/wiki/ZK%20Configuration%20Reference/zk.xml/The%20session-config%20Element/The%20session-timeout%20Element
Thus could you please post the configuration you are using?
Also why dont you set the session timeout only in the zk.xml?
Best Regards,
Darksu
Hi Darksu,
We are using Weblogic for application server. I will surely try setting the session timeout in zk.xml. Will get back to you with the status.
The configuration in ZK.XML
<client-config>
<disable-behind-modal>true</disable-behind-modal>
<processing-prompt-delay>1</processing-prompt-delay>
<tooltip-delay>100</tooltip-delay>
<resend-delay>-1</resend-delay>
</client-config>
<desktop-config>
<desktop-timeout>3600</desktop-timeout>
<file-check-period>5</file-check-period>
<theme-provider-class>
com.xyz.sgv.zk.theme.XYZThemeProvider
</theme-provider-class>
</desktop-config>
<system-config>
<disable-event-thread>false</disable-event-thread>
<max-upload-size>-1</max-upload-size>
<id-generator-class>com.xyz.sgv.common.util.SequenceIdGenerator</id-generator-class>
</system-config>
<error-page>
<device-type>ajax</device-type>
<exception-type>java.lang.Throwable</exception-type>
<location>/Error.zul</location>
</error-page>
<listener>
<description>ThreadLocal Synchronization Listener</description>
<listener-class>org.zkoss.zkplus.util.ThreadLocalListener
</listener-class>
</listener>
<preference>
<name>ThreadLocal</name>
<value> org.springframework.security.context.ThreadLocalSecurityContextHolderStrategy=contextHolder;
com.xyz.sgv.acl.context.ThreadLocalWebContextHolderStrategy=contextHolder;
org.springframework.web.context.request.RequestContextHolder=requestAttributesHolder,inheritableRequestAttributesHolder;
</value>
</preference>
Thank You..
Asked: 2014-12-23 10:56:20 +0800
Seen: 19 times
Last updated: Dec 29 '14
href mailto: causes session timeout
How do I override the timeout-message title?
Often redirects to timeout.zul
post global command on different session (update ui on different session)
zk session in oracle coherence cache session
Are Composers placed in HttpSession?
Tomcat Session Replication: Unable to receive message through TCP channel