Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upAny plans for Canonical Peer Priority #1406
Comments
This comment has been minimized.
This comment has been minimized.
|
Hey @norzak, Just to make it easier for others, the BEP referenced is BEP40. This seems like it could possibly be implemented within the We would also need a way to determine the clients ip address as I don't believe we currently have a way. I would love for somebody to double check this to make sure I'm not missing something. |
This comment has been minimized.
This comment has been minimized.
|
Hi @SilentBot1, On the webtorrent.io page, during streaming video from the peers, I see some IP addresses connecting to mine in a visual animation. Where are those IPs coming from? |
This comment has been minimized.
This comment has been minimized.
|
Hey @norzak, After digging into it, if the peer is added via ip:port (so not a WebRTC peer) then this is just split and added to the wire object, if the peer is added via WebRTC offer the information is pulled from the offer. After poking into the WebRTC offers a bit, it exposes both the local and remote ip address so that would make calculating the formula quite easy. The only issue I see with WebRTC is there is no queue, offers are responded to the instant they are received unlike TCP which has a queue of peers. As for standard TCP peers, a package like public-ip would likely need to be used to discover the servers external IP when opearting behind a NAT to allow for calculation of the formula, though this wouldn't be needed if the torrent was operating locally within a LAN. Most of this is me just writing down my thoughts, so any second opinions would be appreciated. |
Any plans to implement new bittorrent enhancement titled "Canonical Peer Priority"? which connects to geographically closer peers?