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

add an integration test for muxer selection #1887

Merged
merged 4 commits into from
Nov 17, 2022

Conversation

marten-seemann
Copy link
Contributor

@marten-seemann marten-seemann commented Nov 16, 2022

Fixes #1836. Depends on #1885. Closes #1851. Closes #1840.

The test currently fails since apparently the early muxer negotiation respects the server's preferences, not the client's. We should fix that. Will do in another PR.

@MarcoPolo MarcoPolo changed the base branch from master to remove-muxer-multistream November 16, 2022 17:50
@MarcoPolo
Copy link
Collaborator

fyi I moved the base to remove-muxer-multistream

Copy link
Collaborator

@MarcoPolo MarcoPolo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lg, one nit.

p2p/net/upgrader/upgrader.go Outdated Show resolved Hide resolved
@@ -182,6 +182,7 @@ func (cfg *Config) addTransports(h host.Host) error {
fx.ParamTags(`group:"security"`),
)),
fx.Supply(cfg.Muxers),
fx.Supply(h.ID()),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Did this not work before?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The insecure transport consume the peer.ID:

func NewWithIdentity(protocolID protocol.ID, id peer.ID, key ci.PrivKey) *Transport {

The other transports consume the private key.

@marten-seemann marten-seemann changed the base branch from remove-muxer-multistream to master November 16, 2022 23:03
@marten-seemann
Copy link
Contributor Author

Rebased and changed merge target back to master.

@marten-seemann marten-seemann merged commit da9005d into master Nov 17, 2022
@marten-seemann marten-seemann deleted the muxer-integration-test branch November 17, 2022 00:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create integration test for libp2p early muxer negotiation
2 participants