bittorrent-protocol | Simple , robust , BitTorrent peer wire protocol implementation | Stream Processing library
kandi X-RAY | bittorrent-protocol Summary
kandi X-RAY | bittorrent-protocol Summary
Simple, robust, BitTorrent peer wire protocol implementation
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Xor op .
bittorrent-protocol Key Features
bittorrent-protocol Examples and Code Snippets
Community Discussions
Trending Discussions on bittorrent-protocol
QUESTION
I am creating a bittorrent client and am trying to communicate to peers that I need to be unchoked to eventually receive pieces.
I have been sending unchoke and interested messages to the peers, I expect that they send my an unchoke message back, but have not succeeded in receiving it
I am following this article mainly, which states that you must send an interested message after creating a handshake (which I have done successfully)
here is the code I use to create the interested message
...ANSWER
Answered 2018-Dec-08 at 22:58Sending an interested message does not guarantee you get an unchoke message. Signalling interest merely means that a peer will consider you as an unchoking candidate. In other words you have to wait. How long depends on the decision-making of the remote peers.
Signalled interest is not a form of request for which there is an expected response. It merely advertises your current state to all peers you are connected to. Some of which may choose to unchoke you at some point in the future, others may not and the unchokes will change over time. They are more likely to unchoke you when you're uploading data to them. See the bittorrent economics paper for a baseline how clients are expected to behave in aggregate.
The fast extension provides more prompt behavior during startup. Peers generally follow a common algorithm to calculate a set of pieces which you are allowed to download and then tell you which set they have calculated, you may then request those pieces without being unchoked.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install bittorrent-protocol
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page