![]() |
Page History
Wiki Markup |
---|
{scrollbar:icons=false} h1. Problem: My caArray inactivity timeout delay stays stuck at 30 minutes no matter what I set the delay setting to in JBoss. Topic: caArray Usage Release: caArray 2.0 and above Date entered: 10/27/2011 h2. Solution caArray has its own internal mechanism for setting the timeout delay; this mechanism overrides any timeout setting specified by your JBoss installation. This article explains how to change caArray's timeout delay by editing a setting in the 'web.XML' file found in the 'caarray.EAR' application archive. h2. Overview The timeout delay, defined as the duration of inactivity before the session times out and the user is logged out, is specified by the value of the <session-timeout> tag in the 'web.XML' file. The default value, in minutes, is '30', as shown below: \\ *<session-timeout>30</session-timeout>* \\ This value can be changed to any positive integer. \\ The 'web.XML' file must be extracted from the 'caarray.EAR' archive before it can be edited. Once it has been edited, the file must be re-packaged into 'caarray.EAR', and the original 'caarray.EAR' in your caArray installation folder must be overwritten with the modified version. h2. Prerequisites In order to manage EAR and WAR archives, you will need an archive utility with support for the ZIP format. The utility used in this article is WinZip ([www.winzip.com|http://www.winzip.com]), which is freely available. h2. Caveats and Warnings \\ JBoss provides its own mechanism for altering the session timeout delay for applications running within a JBoss instance. However, *the caArray-specific timeout setting as specified in 'web.XML' overrides the JBoss-general setting*. In other words, *the JBoss timeout setting is irrelevant in caArray; in order to change the caArray timeout delay, you must follow the procedure outlined in this article.* If you do not follow this procedure, your caArray timeout delay will remain at the application's default of 30 minutes regardless of what your JBoss timeout is set to. h2. Reference Information * The 'caarray.EAR' archive is located at the following path: \\ *_\[MATKC:caArray installation folder\]_{*}*\{*}{*}_\[MATKC:JBoss installation folder\]_{*}*\server\deploy* \\ In our example, the caArray installation folder is named 'caarray' and the JBoss installation folder is named 'jboss-4.0.5.GA', so the fully qualified path of the EAR archive is: \\ *caarray\jboss-4.0.5.GA\server\deploy\caarray.ear* \\ * The 'caarray.WAR' archive which directly contains the 'web.xml' file is contained within the 'caarray.EAR' archive and is located at the root level of the extracted 'caArray.EAR' folder. \\ * The 'web.XML' file is contained within the 'caarray.WAR' archive and is located at the following path within the extracted 'caarray.WAR' folder: \\ *_\[MATKC:WAR folder path\]_{*}*\WEB-INF* \\ h2. Summary and Review of Procedure In summary, to change the session timeout delay: \\ # Log out of any existing caArray session and shut down any running JBoss instance # Extract the 'caarray.EAR' archive using WinZip or your archive utility of choice. # Locate the 'caarray.WAR' archive found in the extracted EAR folder, then extract this archive. # Locate the 'web.XML' file found in the 'WEB-INF' folder within the extracted WAR folder and open it in a text editor like Windows Notepad. # Find the <session-timeout> tag in 'web.XML' and change the corresponding value to a positive integer representing the number of minutes before the session will time out due to user inactivity. # Save your changes to 'web.XML'. # Use your archive utility to re-create the 'caarray.WAR' archive, incorporating the modified 'web.XML' file. (You can create the archive as a ZIP file, then rename the ZIP extension to WAR, so long as you do not alter the structure of the WAR folder hierarchy.) # Use your archive utility to re-create the 'caarray.EAR' archive, incorporating the re-created 'caarray.WAR' file from the previous step. (You can create the archive as a ZIP file, then rename the ZIP extension to EAR, so long as you do not alter the structure of the EAR folder hierarchy.) # Copy the re-created 'caarray.EAR' file to the path *_\[MATKC:caArray installation folder\]_{*}*\{*{*}_}\[MATKC:JBoss installation folder\]_{*}*\server\deploy*, overwriting the existing 'caarray.EAR'. # Re-launch JBoss and log back into caArray. # To test the new timeout delay, perform any function in your caArray session, then refrain from using the program for at least the number of minutes you specified in 'web.XML'. Make sure not to move your mouse arrow or press any keys on the keyboard during this time. # To verify that your session has timed out, try to perform another function in caArray. If the session has indeed timed out, you should be re-directed to the login screen. h2. Have a comment? Please leave your comment in the [caArray End User Forum|https://cabig-kc.nci.nih.gov/Molecular/forums/viewforum.php?f=6&sid=d297ed62850db647e795b9aa1d18cb7f]. {scrollbar:icons=false} |