Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate mplex module in libp2p #3677

Closed
thomaseizinger opened this issue Mar 25, 2023 · 1 comment · Fixed by #3689
Closed

Deprecate mplex module in libp2p #3677

thomaseizinger opened this issue Mar 25, 2023 · 1 comment · Fixed by #3689
Labels
difficulty:easy getting-started Issues that can be tackled if you don't know the internals of libp2p very well help wanted priority:important The changes needed are critical for libp2p, or are blocking another project

Comments

@thomaseizinger
Copy link
Contributor

The recommended muxer (on top of single-stream transports like TCP) is yamux: https://github.com/libp2p/specs/blob/master/connections/README.md#interoperability

The API of our facade crate should represent the recommended modules that users should use. Currently, it still includes mplex but we don't recommend that anymore as yamux is strictly better.

To resolve this, we should mark the mplex module as #[deprecated] and encourage users to depend on it separately in case they need it.

This way, doing the "right" thing, (using yamux) is easy and the "wrong" thing (using mplex) is hard and annoying, which hopefully will discourage use. We don't want to make it impossible (yet) to use mplex to allow for legacy usecases.

The implementation should be done in a similar manner as #3580.

@thomaseizinger thomaseizinger added priority:important The changes needed are critical for libp2p, or are blocking another project difficulty:easy help wanted getting-started Issues that can be tackled if you don't know the internals of libp2p very well labels Mar 25, 2023
@tcoratger
Copy link
Contributor

I'll take this one :)

@mergify mergify bot closed this as completed in #3689 Apr 4, 2023
mergify bot pushed a commit that referenced this issue Apr 4, 2023
`mplex` module (no flow control and no streams limit) is deprecated to encourage `yamux` usage.

Resolves #3677.

Pull-Request: #3689.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty:easy getting-started Issues that can be tackled if you don't know the internals of libp2p very well help wanted priority:important The changes needed are critical for libp2p, or are blocking another project
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants