mirror of
https://github.com/fluencelabs/rust-libp2p
synced 2025-06-28 17:21:34 +00:00
protocols/kad: Remove deprecated set_protocol_name()
(#2866)
This commit is contained in:
@ -47,6 +47,10 @@
|
|||||||
|
|
||||||
- Update to [`libp2p-tcp` `v0.37.0`](transports/tcp/CHANGELOG.md#0370).
|
- Update to [`libp2p-tcp` `v0.37.0`](transports/tcp/CHANGELOG.md#0370).
|
||||||
|
|
||||||
|
- Update to [`libp2p-metrics` `v0.10.0`](misc/metrics/CHANGELOG.md#0100).
|
||||||
|
|
||||||
|
- Update to [`libp2p-kad` `v0.41.0`](protocols/kad/CHANGELOG.md#0410).
|
||||||
|
|
||||||
# 0.48.0
|
# 0.48.0
|
||||||
|
|
||||||
- Update to [`libp2p-core` `v0.36.0`](core/CHANGELOG.md#0360).
|
- Update to [`libp2p-core` `v0.36.0`](core/CHANGELOG.md#0360).
|
||||||
|
@ -85,8 +85,8 @@ libp2p-core = { version = "0.36.0", path = "core", default-features = false }
|
|||||||
libp2p-dcutr = { version = "0.6.0", path = "protocols/dcutr", optional = true }
|
libp2p-dcutr = { version = "0.6.0", path = "protocols/dcutr", optional = true }
|
||||||
libp2p-floodsub = { version = "0.39.0", path = "protocols/floodsub", optional = true }
|
libp2p-floodsub = { version = "0.39.0", path = "protocols/floodsub", optional = true }
|
||||||
libp2p-identify = { version = "0.39.0", path = "protocols/identify", optional = true }
|
libp2p-identify = { version = "0.39.0", path = "protocols/identify", optional = true }
|
||||||
libp2p-kad = { version = "0.40.0", path = "protocols/kad", optional = true }
|
libp2p-kad = { version = "0.41.0", path = "protocols/kad", optional = true }
|
||||||
libp2p-metrics = { version = "0.9.0", path = "misc/metrics", optional = true }
|
libp2p-metrics = { version = "0.10.0", path = "misc/metrics", optional = true }
|
||||||
libp2p-mplex = { version = "0.36.0", path = "muxers/mplex", optional = true }
|
libp2p-mplex = { version = "0.36.0", path = "muxers/mplex", optional = true }
|
||||||
libp2p-noise = { version = "0.39.0", path = "transports/noise", optional = true }
|
libp2p-noise = { version = "0.39.0", path = "transports/noise", optional = true }
|
||||||
libp2p-ping = { version = "0.39.0", path = "protocols/ping", optional = true }
|
libp2p-ping = { version = "0.39.0", path = "protocols/ping", optional = true }
|
||||||
|
@ -1,3 +1,7 @@
|
|||||||
|
# 0.10.0 [unreleased]
|
||||||
|
|
||||||
|
- Update to `libp2p-kad` `v0.41.0`.
|
||||||
|
|
||||||
# 0.9.0
|
# 0.9.0
|
||||||
|
|
||||||
- Update to `libp2p-swarm` `v0.39.0`.
|
- Update to `libp2p-swarm` `v0.39.0`.
|
||||||
|
@ -3,7 +3,7 @@ name = "libp2p-metrics"
|
|||||||
edition = "2021"
|
edition = "2021"
|
||||||
rust-version = "1.56.1"
|
rust-version = "1.56.1"
|
||||||
description = "Metrics for libp2p"
|
description = "Metrics for libp2p"
|
||||||
version = "0.9.0"
|
version = "0.10.0"
|
||||||
authors = ["Max Inden <mail@max-inden.de>"]
|
authors = ["Max Inden <mail@max-inden.de>"]
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
repository = "https://github.com/libp2p/rust-libp2p"
|
repository = "https://github.com/libp2p/rust-libp2p"
|
||||||
@ -22,7 +22,7 @@ dcutr = ["libp2p-dcutr"]
|
|||||||
libp2p-core = { version = "0.36.0", path = "../../core", default-features = false }
|
libp2p-core = { version = "0.36.0", path = "../../core", default-features = false }
|
||||||
libp2p-dcutr = { version = "0.6.0", path = "../../protocols/dcutr", optional = true }
|
libp2p-dcutr = { version = "0.6.0", path = "../../protocols/dcutr", optional = true }
|
||||||
libp2p-identify = { version = "0.39.0", path = "../../protocols/identify", optional = true }
|
libp2p-identify = { version = "0.39.0", path = "../../protocols/identify", optional = true }
|
||||||
libp2p-kad = { version = "0.40.0", path = "../../protocols/kad", optional = true }
|
libp2p-kad = { version = "0.41.0", path = "../../protocols/kad", optional = true }
|
||||||
libp2p-ping = { version = "0.39.0", path = "../../protocols/ping", optional = true }
|
libp2p-ping = { version = "0.39.0", path = "../../protocols/ping", optional = true }
|
||||||
libp2p-relay = { version = "0.12.0", path = "../../protocols/relay", optional = true }
|
libp2p-relay = { version = "0.12.0", path = "../../protocols/relay", optional = true }
|
||||||
libp2p-swarm = { version = "0.39.0", path = "../../swarm" }
|
libp2p-swarm = { version = "0.39.0", path = "../../swarm" }
|
||||||
|
@ -1,3 +1,10 @@
|
|||||||
|
# 0.41.0 [unreleased]
|
||||||
|
|
||||||
|
- Remove deprecated `set_protocol_name()` from `KademliaConfig` & `KademliaProtocolConfig`.
|
||||||
|
Use `set_protocol_names()` instead. See [PR 2866].
|
||||||
|
|
||||||
|
[PR 2866]: https://github.com/libp2p/rust-libp2p/pull/2866
|
||||||
|
|
||||||
# 0.40.0
|
# 0.40.0
|
||||||
|
|
||||||
- Add support for multiple protocol names. Update `Kademlia`, `KademliaConfig`,
|
- Add support for multiple protocol names. Update `Kademlia`, `KademliaConfig`,
|
||||||
|
@ -3,7 +3,7 @@ name = "libp2p-kad"
|
|||||||
edition = "2021"
|
edition = "2021"
|
||||||
rust-version = "1.56.1"
|
rust-version = "1.56.1"
|
||||||
description = "Kademlia protocol for libp2p"
|
description = "Kademlia protocol for libp2p"
|
||||||
version = "0.40.0"
|
version = "0.41.0"
|
||||||
authors = ["Parity Technologies <admin@parity.io>"]
|
authors = ["Parity Technologies <admin@parity.io>"]
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
repository = "https://github.com/libp2p/rust-libp2p"
|
repository = "https://github.com/libp2p/rust-libp2p"
|
||||||
|
@ -228,16 +228,6 @@ impl KademliaConfig {
|
|||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets a custom protocol name.
|
|
||||||
///
|
|
||||||
/// Kademlia nodes only communicate with other nodes using the same protocol
|
|
||||||
/// name. Using a custom name therefore allows to segregate the DHT from
|
|
||||||
/// others, if that is desired.
|
|
||||||
#[deprecated(since = "0.40.0", note = "use `set_protocol_names()` instead")]
|
|
||||||
pub fn set_protocol_name(&mut self, name: impl Into<Cow<'static, [u8]>>) -> &mut Self {
|
|
||||||
self.set_protocol_names(std::iter::once(name.into()).collect())
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Sets the timeout for a single query.
|
/// Sets the timeout for a single query.
|
||||||
///
|
///
|
||||||
/// > **Note**: A single query usually comprises at least as many requests
|
/// > **Note**: A single query usually comprises at least as many requests
|
||||||
|
@ -159,13 +159,6 @@ impl KademliaProtocolConfig {
|
|||||||
self.protocol_names = names;
|
self.protocol_names = names;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Sets single protocol name used on the wire. Can be used to create incompatibilities
|
|
||||||
/// between networks on purpose.
|
|
||||||
#[deprecated(since = "0.40.0", note = "use `set_protocol_names()` instead")]
|
|
||||||
pub fn set_protocol_name(&mut self, name: impl Into<Cow<'static, [u8]>>) {
|
|
||||||
self.set_protocol_names(std::iter::once(name.into()).collect());
|
|
||||||
}
|
|
||||||
|
|
||||||
/// Modifies the maximum allowed size of a single Kademlia packet.
|
/// Modifies the maximum allowed size of a single Kademlia packet.
|
||||||
pub fn set_max_packet_size(&mut self, size: usize) {
|
pub fn set_max_packet_size(&mut self, size: usize) {
|
||||||
self.max_packet_size = size;
|
self.max_packet_size = size;
|
||||||
|
Reference in New Issue
Block a user