mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore: move ratelimit type to tokio util (#9007)
This commit is contained in:
3
Cargo.lock
generated
3
Cargo.lock
generated
@ -6739,8 +6739,8 @@ dependencies = [
|
|||||||
"rand 0.8.5",
|
"rand 0.8.5",
|
||||||
"reth-chainspec",
|
"reth-chainspec",
|
||||||
"reth-ethereum-forks",
|
"reth-ethereum-forks",
|
||||||
"reth-net-common",
|
|
||||||
"reth-network-peers",
|
"reth-network-peers",
|
||||||
|
"reth-tokio-util",
|
||||||
"reth-tracing",
|
"reth-tracing",
|
||||||
"schnellru",
|
"schnellru",
|
||||||
"secp256k1",
|
"secp256k1",
|
||||||
@ -7225,7 +7225,6 @@ name = "reth-net-common"
|
|||||||
version = "1.0.0-rc.2"
|
version = "1.0.0-rc.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"tokio",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
|
|||||||
@ -13,7 +13,4 @@ workspace = true
|
|||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
|
|
||||||
# async
|
|
||||||
tokio = { workspace = true, features = ["time"] }
|
|
||||||
@ -9,5 +9,3 @@
|
|||||||
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
|
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
|
||||||
|
|
||||||
pub mod ban_list;
|
pub mod ban_list;
|
||||||
|
|
||||||
pub mod ratelimit;
|
|
||||||
|
|||||||
@ -14,8 +14,8 @@ workspace = true
|
|||||||
[dependencies]
|
[dependencies]
|
||||||
# reth
|
# reth
|
||||||
reth-ethereum-forks.workspace = true
|
reth-ethereum-forks.workspace = true
|
||||||
reth-net-common.workspace = true
|
|
||||||
reth-network-peers = { workspace = true, features = ["secp256k1"] }
|
reth-network-peers = { workspace = true, features = ["secp256k1"] }
|
||||||
|
reth-tokio-util = { workspace = true, features = ["time"] }
|
||||||
|
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
|
|||||||
@ -7,7 +7,7 @@ use crate::{
|
|||||||
tree::{DnsEntry, LinkEntry, TreeRootEntry},
|
tree::{DnsEntry, LinkEntry, TreeRootEntry},
|
||||||
};
|
};
|
||||||
use enr::EnrKeyUnambiguous;
|
use enr::EnrKeyUnambiguous;
|
||||||
use reth_net_common::ratelimit::{Rate, RateLimit};
|
use reth_tokio_util::ratelimit::{Rate, RateLimit};
|
||||||
use std::{
|
use std::{
|
||||||
collections::VecDeque,
|
collections::VecDeque,
|
||||||
future::Future,
|
future::Future,
|
||||||
|
|||||||
@ -19,4 +19,7 @@ tokio = { workspace = true, features = ["sync"] }
|
|||||||
tokio-stream = { workspace = true, features = ["sync"] }
|
tokio-stream = { workspace = true, features = ["sync"] }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
tokio = { workspace = true, features = ["full", "macros"] }
|
tokio = { workspace = true, features = ["full", "macros"] }
|
||||||
|
|
||||||
|
[features]
|
||||||
|
time = ["tokio/time"]
|
||||||
@ -12,3 +12,6 @@ mod event_sender;
|
|||||||
mod event_stream;
|
mod event_stream;
|
||||||
pub use event_sender::EventSender;
|
pub use event_sender::EventSender;
|
||||||
pub use event_stream::EventStream;
|
pub use event_stream::EventStream;
|
||||||
|
|
||||||
|
#[cfg(feature = "time")]
|
||||||
|
pub mod ratelimit;
|
||||||
|
|||||||
Reference in New Issue
Block a user