Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question concerning WS (not issue) #1024

Closed
CraigglesO opened this issue Jan 24, 2017 · 4 comments
Closed

Question concerning WS (not issue) #1024

CraigglesO opened this issue Jan 24, 2017 · 4 comments

Comments

@CraigglesO
Copy link

@CraigglesO CraigglesO commented Jan 24, 2017

I've been looking over the code and I realized that you just reused the bittorent protocol (wire) with ws.

However, I can't seem to understand how you implemented the ws server and client?

Did you use websocket-stream package? If you could point me to the code that explicitly preps the conditions (as I don't see it inside Peer or webconn) that would really help! Or just a quick paragraph explanation.

Also seems like you follow BEP 19 for website based DL. So It's all rather confusing as how to understand where to start.

@DiegoRBaquero

This comment has been minimized.

Copy link
Member

@DiegoRBaquero DiegoRBaquero commented Jan 24, 2017

The ws is not used for the bittorrent protocol, webrtc is. It is used only for the tracking.

@CraigglesO

This comment has been minimized.

Copy link
Author

@CraigglesO CraigglesO commented Jan 24, 2017

I thought ws was built on webrtc.... I have a lot to learn about this...

@feross

This comment has been minimized.

Copy link
Member

@feross feross commented Jan 24, 2017

The bittorrent-tracker package connects to tracker servers. There are 3 types: http, udp, and ws (websocket). The websocket trackers are the only kind that can introduce you to webrtc peers.

You can look at this file to see how the webrtc connections are created during communication with the tracker: https://github.com/feross/bittorrent-tracker/blob/master/lib/client/websocket-tracker.js

@feross feross closed this Jan 24, 2017
@lock

This comment has been minimized.

Copy link

@lock lock bot commented May 4, 2018

This thread has been automatically locked because it has not had recent activity. To discuss futher, please open a new issue.

@lock lock bot locked as resolved and limited conversation to collaborators May 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.