Simple tip today but probably most of my friend coming from FORMS background are not familiar with this. Where and how to set the Session time out setting in Oracle ADF application? Answer is with every application there is a file called web.xml file in your ViewController Project WEB-INF folder. The file which contains configuration settings for your web application on run-time. JDeveloper provides a declarative way to modify this settings by default the session timeout is 35 minutes.
Here what documentation says
Session Timeout
(Optional) Enter an integer value of minutes of inactivity are required before you want to force your web application's sessions to expire. Corresponds to thetag of the subelement. Note, this value can be overridden for individual sessions by means of the setMaxInactiveInterval() method of the javax.servlet.http.HttpSession interface.
Here is the setting in Jdeveloper
after deployment you can see the timeout value in the deployment properties of your application as well here the screen shot of weblogic console
On runtime if session expires you will get the similar message
Happy Jdeveloping,
Zeeshan Baig
Which one takes priority
ReplyDeleteThe setting in the web.xml or what is defined in the weblogic
This comment has been removed by the author.
DeleteSo from what you are saying. If I set it globally in weblogic to a different value in weblogic, it will override the value in web.xml?
DeleteHi,
DeleteOK i got it what you mean.... Ignore my last reply...
By setting it on web.xml and weblogic have same impact. both values are coming from web.xml but if you redeploy your application then you might lose your weblogic configuration.
As best practice set it to web.xml and in weblogic it is also displaying application specific values not global (there is no global value for ADF application)
ZB
What could be the reasons where session timeout does not work? I tried first by updating web.xml (1min) and then weblogic.xml (60 secs). Both of them does not override the default timeout - 35 mins.
DeleteHi,
DeleteAre you using ADF application or any other product like webcenter etc etc ?
Zeeshan
i am using ADF application.
DeleteInterestingly, setting the timeout to 5 minutes in web.xml works. I don't know why 1 minute is not working.
DeleteSome times it is cache of server.
DeleteWhat if the application is webcenter portal
ReplyDeleteHi,
DeleteCheck webcenter portal documentation. I have done in webcenter spaces application (very old one) you have to find the web.xml that it uses. For Portal it should be straight forward.
Regards,
Zeeshan