Collection type storage

8 views
Skip to first unread message

Melvin Gilberto

unread,
Dec 27, 2019, 2:43:46 PM12/27/19
to OpenVidu
Hello, I am currently developing an application in which I implement OpenVidu as a means of transmissions,
Is it advisable to store the sessions and tokens in the database? and manage the collections in the database or it is much more advisable to leave it as they currently have in the examples, within the following variables.


this.mapSessions.put(sessionName, session);
this.mapSessionNamesTokens.put(sessionName, new ConcurrentHashMap<>());
this.mapSessionNamesTokens.get(sessionName).put(token, role);

Where these variables store sessions and tokens.

Micael Gallego

unread,
Jan 2, 2020, 7:01:32 AM1/2/20
to Melvin Gilberto, OpenVidu
You can manage session information on memory or database, whatever suits you best.

Best regards

Micael Gallego
Kurento / OpenVidu Project Lead


--
You received this message because you are subscribed to the Google Groups "OpenVidu" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openvidu+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/openvidu/9d3d217a-58b1-4fc7-b13f-53bc6c4e53a5%40googlegroups.com.

Pablo

unread,
Jan 2, 2020, 7:23:07 AM1/2/20
to OpenVidu
You can use whatever mehtod you prefer. But be sure to be consistent with the information stored in your DB. The only "real" status of sessions is given by OpenVidu Server, so make sure the information you store at any moment really corresponds to the information returned by OpenVidu Server.
Reply all
Reply to author
Forward
0 new messages