Reputation: 1471
I would like to implement a chatting functionality in my web application without video chat so I need to connect to an OpenTok Session. If I need to start a video call, I will connect to another OpenTok Session.
Would there be a problem if I connect to 2 different OpenTok sessions? Would having 2 OpenTok objects be heavy to the browser?
Upvotes: 0
Views: 193
Reputation: 1515
TokBox Developer Evangelist here.
As Fran mentioned, you can have as many instances of the OpenTok Session as you'd like, but we can't really gauge the impact on the performance because it's very much dependent on your hardware and how you've built the application.
Also just to clarify, you do not need to create another session to start publishing at a later time. The publisher is only created when you call the OT.initPublisher
method and publishing only begins when you call session.publish
.
Upvotes: 1
Reputation: 294
Opentok QA staff here,
You can have many open sessions at the same time, even in the same browser. You can have 4, 5, 6... depending on your computer, number of cores, RAM available, etc. But, definitely, yes, that is perfectly possible.
Upvotes: 2