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

Don't wait timeout on http failure (webseed) #1504

Open
Chocobozzz opened this issue Sep 12, 2018 · 7 comments
Open

Don't wait timeout on http failure (webseed) #1504

Chocobozzz opened this issue Sep 12, 2018 · 7 comments

Comments

@Chocobozzz
Copy link
Contributor

@Chocobozzz Chocobozzz commented Sep 12, 2018

What version of WebTorrent?
0.102.1

What operating system and Node.js version?
Browser

What browser and version? (if using WebTorrent in the browser)
Chromium 69

What did you expect to happen?

With a torrent having 2 webseed endpoints, if 1 webseed fails to respond webtorrent should not wait wire timeout before getting the chunk on the other webseed.

What actually happened?

Webtorrent waits the wire timeout (~30 seconds), and then get the chunk from the other http endpoint. Could be annoying when we want to stream the torrent file in a video element.

The wire get the error here but do nothing (do not call the callback with an error as argument for example): https://github.com/webtorrent/bittorrent-protocol/blob/master/index.js#L496

And so we get the timeout here: https://github.com/webtorrent/bittorrent-protocol/blob/master/index.js#L565

Could we call the callback directly in the _onRequest function so we don't have to wait 30 seconds?

PS: Maybe it's the wrong repository for this issue, but I'm not sure where we should handle this case.

@stale

This comment has been minimized.

Copy link

@stale stale bot commented Dec 11, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the stale label Dec 11, 2018
@Chocobozzz

This comment has been minimized.

Copy link
Contributor Author

@Chocobozzz Chocobozzz commented Dec 11, 2018

Don't

@stale stale bot removed the stale label Dec 11, 2018
@stale

This comment has been minimized.

Copy link

@stale stale bot commented Mar 11, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the stale label Mar 11, 2019
@stale stale bot closed this Mar 18, 2019
@Chocobozzz

This comment has been minimized.

Copy link
Contributor Author

@Chocobozzz Chocobozzz commented Mar 18, 2019

Please remove the stale bot, I don't want to comment my issues every 3 months. It has already closed several interesting issues.

@DiegoRBaquero

This comment has been minimized.

Copy link
Member

@DiegoRBaquero DiegoRBaquero commented Mar 18, 2019

@feross

This comment has been minimized.

Copy link
Member

@feross feross commented Sep 5, 2019

Please remove the stale bot, I don't want to comment my issues every 3 months. It has already closed several interesting issues.

Sorry about that @Chocobozzz. The idea is to auto close the tons of silly / half-baked issues that we constantly get. If we apply labels to the interesting issues, they will stay open. I just added you to the WebTorrent organization so you can help add appropriate labels.

As I've been catching up on all my GitHub notification emails from the past months, I've been re-opening any issues that shouldn't have been closed.

I also just increased the stale timeout to 180 days from 90 days.

@Chocobozzz

This comment has been minimized.

Copy link
Contributor Author

@Chocobozzz Chocobozzz commented Sep 5, 2019

Thanks @feross, very happy to see you back :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
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.