webtorrent / webtorrent-hybrid

WebTorrent (with WebRTC support in Node.js)
https://webtorrent.io
MIT License
518 stars 98 forks source link

Swap wrtc for node-datachannel #122

Closed sebastienvercammen closed 2 years ago

sebastienvercammen commented 3 years ago

What is the purpose of this pull request? (put an "X" next to item)

What changes did you make? (Give an overview)

Swapped wrtc for node-datachannel

Which issue (if any) does this pull request address?

Fixes #118. And this comment of a user reporting better results.

An update: as per #118 we tried to replace wrtc with node-datachannel. As a result, the CPU usage is solved.

Also requested by @feross here.

Is there anything you'd like reviewers to focus on?

Code is untested.

The change is minor and presented so everyone can run it and compare the results on their machines to help support the decision to swap or keep wrtc.

It's really tiny, so let's make it easy to make WebTorrent better.

welcome[bot] commented 3 years ago

🙌 Thanks for opening this pull request! You're awesome.

sebastienvercammen commented 3 years ago

CI failure:

CMake Error at CMakeLists.txt:1 (cmake_minimum_required):
  CMake 3.15 or higher is required.  You are running version 3.12.4

and npm warnings, in case anyone wants to contribute to dependencies:

prebuild-install WARN install /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.25' not found (required by /home/travis/build/webtorrent/webtorrent-hybrid/node_modules/node-datachannel/build/Release/node_datachannel.node)
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated request-promise-native@1.0.9: request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
ZenDarkmaster commented 3 years ago

Everything has been successfully compiled with absolutely no errors I use - nvm | npm 6.14.9 / nodejs v14.15.3

Announce does not work with this fix I don't see the record in the tracker, if you use the original version, the record appears in the tracker.

webtorrent-hybrid seed Test8.mp4 -a ws://localhost:1337

image

What could be the problem?

lucybythec commented 3 years ago

Unfortunately, as we found out, this doesn't really work. Please see here:

https://github.com/webtorrent/webtorrent-hybrid/issues/120#issuecomment-756592948

github-actions[bot] commented 2 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?