Tapani Rantakokko 9c8f45cd77
Fixed an attempt to publish video after failure to set the local description. (#174)
When preparing to publish a video stream from an Android client app to OpenVidu session, it is possible that creating video offer succeeds but then setting it as the local description fails.

An example: Android client is configured to use a hardware video encoder, but a particular device does not have one. As a result, SDP description is created without some necessary video elements, and setting it as the local description fails at runtime.

The original code did not check the result of setting a local description before it went on to attempt publishing video. This resulted to breaking the whole OpenVidu session with rather severe consequences:
- various errors in server and client logs
- every participant's video streams stuck
- the session cannot be properly closed (it becomes a ghost session)

This simple fix checks if setting the local description succeeds, and only then attempts to publish video stream.

While this demo application does not configure HW encoder in use, other developers will use it as a basis for their apps. In addition, there can be other reasons why setting local description may fail. Hence, it should be checked.
2022-05-18 13:15:56 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2020-11-04 13:23:36 +01:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2022-05-18 12:24:09 +02:00
2017-06-09 11:24:46 +02:00
2021-10-07 12:46:20 +02:00
2022-05-18 12:24:09 +02:00

Backers on Open Collective Sponsors on Open Collective License badge Documentation Status Docker badge Support badge Twitter Follow

openvidu-tutorials

Visit openvidu.io/tutorials

Description
No description provided
Readme Apache-2.0 80 MiB
Languages
JavaScript 36.9%
HTML 15.4%
CSS 14%
Swift 12.6%
TypeScript 8.3%
Other 12.8%