When is a web app in the idle state? How does the session_id​le_timeout​_minutes value affect the termination of a web app?

8 visualizzazioni (ultimi 30 giorni)
I am using MATLAB Web App Server to host several apps. I set the 'session_idle_timeout_minutes' to 1 minute using webapps-config:
webapps-config set session_idle_timeout_minutes 1
 and restarted the server.
However, this didn't really terminate the session after 1 minute of idle time. Even after 5 minutes the session is still available -- I just left the tab open in the background and came back to the web app after five minutes. After five minutes the app was still working and it was in the same state as before when I left it five minutes before.
Please clarify what is considered 'idle' according to the webapp? 

Risposta accettata

MathWorks Support Team
MathWorks Support Team il 20 Nov 2025 alle 0:00
The app will keep running as long as the tab is open. If you will close the tab, the worker process running your app on server will terminate within 30s. Sometimes due to network disconnect, browser hang, or other reasons your browser session may still appear to be running in the tab, but will stop communicating with the server. session_idle_timeout_minutes will define after how many minutes this session will be considered abandoned in this scenario and will be stopped. 
We do not have a limit on session duration. You can build it into your app, or can establish a maximum user session as a part of authentication by setting tokenExpirationMin value in webapps_authn.json file. After your authentication token expiration, within session_idle_timeout_minutes your app session will terminate. This may cause your app session to terminate sooner than expected though.

Più risposte (0)

Categorie

Scopri di più su MATLAB Web App Server in Help Center e File Exchange

Tag

Non è stata ancora inserito alcun tag.

Prodotti


Release

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by