Skip to content

Commit b711f09

Browse files
committed
Fix incorrect inbound request count causing rate limiting.
1 parent 7206909 commit b711f09

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

beacon_node/lighthouse_network/src/rpc/methods.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -308,9 +308,7 @@ pub struct DataColumnsByRangeRequest {
308308

309309
impl DataColumnsByRangeRequest {
310310
pub fn max_requested<E: EthSpec>(&self) -> u64 {
311-
self.count
312-
.saturating_mul(E::max_blobs_per_block() as u64)
313-
.saturating_mul(self.columns.len() as u64)
311+
self.count.saturating_mul(self.columns.len() as u64)
314312
}
315313

316314
pub fn ssz_min_len() -> usize {

beacon_node/lighthouse_network/src/rpc/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,8 +366,10 @@ where
366366
protocol,
367367
Protocol::BlocksByRange
368368
| Protocol::BlobsByRange
369+
| Protocol::DataColumnsByRange
369370
| Protocol::BlocksByRoot
370371
| Protocol::BlobsByRoot
372+
| Protocol::DataColumnsByRoot
371373
) {
372374
debug!(self.log, "Request too large to process"; "request" => %req, "protocol" => %protocol);
373375
} else {

0 commit comments

Comments
 (0)