libp2p / libp2p/unified-testing
chromium-rust-v0.53 WASM to jvm-v1.2 WebSocket/mplex timeout
Nobody has claimed this yet.
- Dominant language
- Shell
- Stars
- 7
- Forks
- 19
- PR merge metrics
- No merged PRs in 30d
Description
**Repos:**
- [libp2p/rust-libp2p](https://github.com/libp2p/rust-libp2p) WASM build (commit `b7914e407da34c99fb76dcc300b3d44b9af97fac`)
- [libp2p/jvm-libp2p](https://github.com/libp2p/jvm-libp2p) (commit `737456de5d96db030aa04c8527585af1a510898f`)
**Transport:** ws, **Secure:** noise, **Muxer:** mplex
## Summary
chromium-rust-v0.53 (WASM build running in Chromium) times out when dialing jvm-v1.2 as listener via ws/noise/mplex. The JVM listener starts successfully and publishes its multiaddr, but the WASM dialer never connects. The test hits the 180-second timeout with no output from the dialer container.
The yamux variant of the same test (`chromium-rust-v0.53 x jvm-v1.2 (ws, noise, yamux)`) passes, confirming the issue is specific to mplex muxer negotiation between these two implementations.
## Failing tests (1)
- `chromium-rust-v0.53 x jvm-v1.2 (ws, noise, mplex)`
## Passing variant
- `chromium-rust-v0.53 x jvm-v1.2 (ws, noise, yamux)` — passes in 13s
## Error output
```
Test timed out after 180s
```
No output from the dialer container. The listener log shows successful Redis connection and multiaddr advertisement:
```
Connection established to Redis (Jedis{Connection{DefaultJedisSocketFactory{proxy-b7ff7ce3:6379}}})
Starting listener with advertisedAddress: /ip4/172.18.0.5/tcp/12120/ws/p2p/12D3KooWEZT8uKLqgX2tg6vzf9EaSKET9c1sREZiY5PE9zG9hnfv
```
## Root cause analysis
The WASM rust-libp2p v0.53 dialer and JVM jvm-libp2p v1.2 listener fail to negotiate the mplex muxer over a ws/noise connection. Since the yamux variant works, the noise handshake and WebSocket transport are functioning correctly between these implementations. The failure occurs during or after muxer negotiation when mplex is selected.
Possible causes:
- Incompatible mplex protocol version or framing between rust-libp2p WASM v0.53 and jvm-libp2p v1.2
- The WASM environment may handle mplex stream initialization differently, causing a deadlock during muxer setup
- jvm-libp2p's mplex implementation may expect a different multistream-select sequence than what the WASM client sends
## Notes
This is distinct from the `chromium-rust-v0.53 x python-v0.x (ws, noise, mplex)` timeout (see `chromium-rust-v053-python-ws-timeout.md`), which involves a different listener implementation. The chromium-rust-v0.53 WASM dialer connects successfully to rust and go listeners via ws/noise/mplex, so the issue is specific to the JVM listener's mplex handling.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the failing `chromium-rust-v0.53 x jvm-v1.2 (ws, noise, mplex)` interoperability test and compare it with the passing yamux variant. Inspect the pinned rust-libp2p and jvm-libp2p commits and the related `chromium-rust-v053-python-ws-timeout.md`; done means the mplex test no longer times out while the yamux and other listener cases remain passing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust, wasm
- Domain
- distributed-systems, networking, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100