爱意满满的作品展示区。
fregie

golang 基于 net.Conn 的连接多路复用库。可用于减少握手时间,聚合链路带宽

  •  
  •   fregie ·
    fregie · Jun 18, 2022 · 3907 views
    This topic created in 1605 days ago, the information mentioned may be changed or developed.

    用途

    • 复用已有连接,省去握手时间。可用于解决多重连接场景下建立连接握手时间太长
    • 聚合多个 IP/服务器,同时聚合带宽,多个低带宽服务器聚合成高带宽
    • 某些情况下聚合多条 TCP 连接可以提高峰值带宽

    仓库: https://github.com/fregie/mpx

    欢迎 star 和 issue 隐藏功能: https://www.v2ex.com/t/860540

    之前发的贴被移到了 Chamber 节点,所以再发一个介绍技术特性的贴

    8 replies  •  2022-06-24 18:06:08 +08:00
    catsoul
    catsoul
    Jun 19, 2022 via iPhone
    1
    有意思,先 clone 了康康
    FrankAdler
    FrankAdler
    Jun 19, 2022 via iPhone
    2
    我理一下思路,是本地连接服务器 a 和 b ,a 再把流量转发给 b ,b 统一转发出去?
    fregie
    fregie
    OP
    Jun 19, 2022
    3
    @FrankAdler 要聚合服务器带宽的话,基本就是这意思
    superhack
    superhack
    Jun 19, 2022
    4
    赞赞赞
    linglin0924
    linglin0924
    Jun 19, 2022
    5
    有点复杂,没搞懂
    Kinnice
    Kinnice
    Jun 21, 2022
    6
    和 haproxy 的负载均衡相比有什么优势吗
    haproxy --> server - 1 --> server - 2
    --> server - 2
    这个思路依托于,云服务器内网互联非常高,下行几乎不限制
    好处在于落地 ip 一致
    fregie
    fregie
    OP
    Jun 21, 2022
    7
    @Kinnice haproxy 对于单连接是无法使用多条链路的
    codeMore
    codeMore
    Jun 24, 2022
    8
    是类似于一个 http 连接池嘛?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4194 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 41ms · UTC 08:32 · PVG 16:32 · LAX 00:32 · JFK 03:32
    ♥ Do have faith in what you're doing.