In order to increase performance and maximise platform, OAM should have a reduced timeout for user sessions. So after that time, user would lose its login cookie and when he/she clicks on any link, an error page would be displayed.
To avoid that, you may use the following workaround:
Add a refresh command in the Portal template header and set the time to the OAM timeout minus 10 seconds, i.e. If OAM timeout is 15 minutes, set the refresh to 890 seconds. As the target URL, specify the OAM logout address, passing as parameter the page to be displayed after logout (end_url). For instance:
<meta http-equiv="refresh" content="890; URL=/../oam/server/logout?end_url=/myApp"/>
This tag must be included in the header of the page, before the pageTemplateDef tag.
As a result, when user inactivity is near OAM timeout, the page will refresh automatically and the application login page will be displayed.
References
Oracle Service Requests: SR 3-9350587377 : OAM11.1.2.2.0 - send error page when come over OAM inactivity timeout
Installing and Configuring OAM with WebCenter Portal
Benefits of Oracle Access Manager
HTML meta tag