Session Timeout

Hello,
I would like to know if a session has an expiration date when it is created and hasn’t been used, or does it always have to be manually destroyed?
Regards

Hi,

Very good question! In 2.12.0 version Sessions that have been created through REST API (or Java/Node SDKs) and that have not had any client connection will remain in memory forever until manually closed. All tokens created for them will also remain available forever. These sessions will only be closed when: A) some user finally connects to the session using a token, and last user disconnects from it. B) Manually closing the session with REST API/Java/Node SDKs.

Alpha version 2.13.0 already introduces automatic close up of sessions that have been initialized but no user connected to them. By default the non-active session garbage collector will run every 15 minutes, closing non-active sessions with more than one hour of life. These 2 parameters will be of course customizable.

Stay tuned!

Regards.

Thank you for your response.
Regards.

Hello,

I’m using OpenVidu 2.17.0, but I can’t find these 2 parameters to configure the automatic closing sessions. It also looks like that sessions stay in memory forever.

OPENVIDU_SESSIONS_GARBAGE_INTERVAL
OPENVIDU_SESSIONS_GARBAGE_THRESHOLD

See https://docs.openvidu.io/en/latest/reference-docs/openvidu-config/