connex-rs: Connex data plane over UCX (one-sided RMA, signals, peer-failure events, same-identity rejoin)
The Connex data plane: Rust over UCX, peer-death events in milliseconds, same-identity rejoin
connex-rs moves pipeline-step data between Connex endpoints and tells them, within milliseconds, when a peer dies. It is a Rust crate over UCX with a Python binding (connex_rs) and is the default data plane of connex.pp in Connex on hosts with a usable RDMA device (CONNEX_PP_BACKEND=auto, or force it with CONNEX_PP_BACKEND=connex-rs; Mooncake Transfer Engine stays available with CONNEX_PP_BACKEND=mooncake).
Same cluster and deployment: Llama-3-8B split into 4 pipeline stages on A40 GPUs, one stage per GPU, InfiniBand between nodes, 2 pipeline replicas with 4 steps in flight per replica (CONNEX_PP_INFLIGHT=4); only CONNEX_PP_BACKEND differs. The steady-state and closed-loop Mooncake numbers were re-measured in the same session as connex-rs; the Mooncake transfer and handover numbers come from the earlier validation of the same setup. Full tables, setup and reproduction commands: docs/results.md in the Connex repository.
Raw transfers, GPU to GPU across nodes, one-sided read of registered GPU memory (GPUDirect RDMA):
Serving, steady state, trace replay, 100% goodput for both:
Where connex-rs is not better: closed-loop throughput is 3% lower (not yet profiled), its TCP path (no RDMA) is several times slower than Mooncake's, which is why auto keeps Mooncake on hosts without RDMA, and individual requests can still stall for up to about 1 s (worst request 1.03 s at 1 step in flight, 0.92 s at 4) even though the per-run medians are far lower.
pip install connex-rs # prebuilt wheel: links the UCX of the build host by rpath; on # RDMA/GPU hosts build from source against your UCX: # Rust toolchain (rustup) and UCX with the transports you need (verbs/rdmacm # for RDMA, CUDA for GPU memory). UCX_HOME points at its prefix. cargo build --release cargo test --release # UCX over TCP on loopback CONNEX_RS_TEST_TLS=rc_mlx5 CONNEX_RS_TEST_IP= UCX_NET_DEVICES= :1 \ cargo test --release # same tests over RDMA # Python wheel (abi3, Python >= 3.8); links UCX by rpath, does not bundle it pip install maturin maturin build --release -o dist && pip install dist/connex_rs-*.whl # backend tests over real Connex endpoints live in the Connex repository: # (in a Connex checkout) python -m pytest tests/test_connexrs_backend.py python python/rma_bench.py local --ip --dev cuda:0 --peer-dev cuda:1 Python API import connex_rs e = connex_rs.Engine("llama-8b", stage=1, shard=0, replica=0, listen_ip="10.0.0.2", port=51001, heartbeat_ms=1000, heartbeat_timeout_ms=3000) e.local_url # "10.0.0.2:51001#llama-8b|1|0|0" e.register_memory(t.data_ptr(), t.numel()) # host or GPU memory e.transfer_sync_read(peer_url, dst_ptr, src_ptr, n) # 0, or < 0 on failure h = e.put_signal(peer_url, src_ptr, dst_ptr, n, b"step 7") # h.wait() e.send_msg(peer_url_or_id_tuple, b"..."); e.recv_msg(timeout_ms=100) e.wait_event(timeout_ms=100) # {"type": "up"|"joined"|"failed", "peer": (...), "reason": ...} e.stats() # endpoints, regions, rkeys, in-flight, failures ... e.close() Return codes of transfer_sync_read / transfer_sync_write: 0 ok, -2 peer failed, -3 timeout (the connection is then closed, so no late DMA lands in the destination), -4 invalid (e.g. no registered region at that address).
Measurements: docs/results.md, section 6, in the Connex repository.
Connex, the communication library for endpoint mobility in distributed LLM serving, installs it with pip install "connex-ai[rs]" and selects it with CONNEX_PP_BACKEND=auto (or connex-rs). Changes are listed in CHANGELOG.md.
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
None of the files in this release were uploaded with provenance metadata.
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.




