mirror of
https://github.com/fluencelabs/rust-libp2p
synced 2025-06-16 03:21:22 +00:00
[swarm] Remove substream-specific protocol negotiation version. (#1962)
* Remove substream-specific protocol negotiation version. Remove the option for a substream-specific multistream select protocol override. The override at this granularity is no longer deemed useful, in particular because it can usually not be configured for existing protocols like `libp2p-kad` and others. There is a `Swarm`-scoped configuration for this version available since [1858](https://github.com/libp2p/rust-libp2p/pull/1858). * Update protocol crate versions and changelogs. * Clean up documentation.
This commit is contained in:
@ -111,8 +111,8 @@ where
|
||||
let proto1 = self.proto1.listen_protocol();
|
||||
let proto2 = self.proto2.listen_protocol();
|
||||
let timeout = *std::cmp::max(proto1.timeout(), proto2.timeout());
|
||||
let (_, u1, i1) = proto1.into_upgrade();
|
||||
let (_, u2, i2) = proto2.into_upgrade();
|
||||
let (u1, i1) = proto1.into_upgrade();
|
||||
let (u2, i2) = proto2.into_upgrade();
|
||||
let choice = SelectUpgrade::new(SendWrapper(u1), SendWrapper(u2));
|
||||
SubstreamProtocol::new(choice, (i1, i2)).with_timeout(timeout)
|
||||
}
|
||||
|
Reference in New Issue
Block a user