Simple-peer: Why the peer returns three signals?

Created on 26 Feb 2018  路  1Comment  路  Source: feross/simple-peer

The peer.on('signal') is triggered more than one time, usually three times, and every time it triggered it returns different signal data with different IP address,

I'm confused should I call peer.signal three times as well?

Thank you

question

Most helpful comment

This is because of Trickle ICE (read, for instance, here: https://webrtcglossary.com/trickle-ice/). Yes, if you have signal event 3 times you need to call peer.signal() method 3 times, otherwise connection might not work.
You can set trickle: false in constructor to get a single event, but it will make connection establishment slower.

>All comments

This is because of Trickle ICE (read, for instance, here: https://webrtcglossary.com/trickle-ice/). Yes, if you have signal event 3 times you need to call peer.signal() method 3 times, otherwise connection might not work.
You can set trickle: false in constructor to get a single event, but it will make connection establishment slower.

Was this page helpful?
0 / 5 - 0 ratings