additional network field, that represents default rate limit measured in blocks

Signed-off-by: Uncle Stretch <uncle.stretch@ghostchain.io>
This commit is contained in:
Uncle Stretch
2025-06-19 21:32:40 +03:00
parent b53a58f431
commit 060f61105c
5 changed files with 142 additions and 8 deletions

View File

@@ -53,6 +53,7 @@ pub trait WeightInfo {
fn update_network_name(n: u32, ) -> Weight;
fn update_network_endpoint(n: u32, ) -> Weight;
fn update_network_finality_delay() -> Weight;
fn update_network_rate_limit_delay() -> Weight;
fn update_network_block_distance() -> Weight;
fn update_network_type() -> Weight;
fn update_network_gatekeeper() -> Weight;
@@ -125,6 +126,18 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
}
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
fn update_network_rate_limit_delay() -> Weight {
// Proof Size summary in bytes:
// Measured: `294`
// Estimated: `3759`
// Minimum execution time: 48_107_000 picoseconds.
Weight::from_parts(48_993_000, 0)
.saturating_add(Weight::from_parts(0, 3759))
.saturating_add(T::DbWeight::get().reads(1))
.saturating_add(T::DbWeight::get().writes(1))
}
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
fn update_network_block_distance() -> Weight {
// Proof Size summary in bytes:
// Measured: `294`
@@ -270,6 +283,18 @@ impl WeightInfo for () {
}
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
fn update_network_rate_limit_delay() -> Weight {
// Proof Size summary in bytes:
// Measured: `294`
// Estimated: `3759`
// Minimum execution time: 48_107_000 picoseconds.
Weight::from_parts(48_993_000, 0)
.saturating_add(Weight::from_parts(0, 3759))
.saturating_add(RocksDbWeight::get().reads(1))
.saturating_add(RocksDbWeight::get().writes(1))
}
/// Storage: `GhostNetworks::Networks` (r:1 w:1)
/// Proof: `GhostNetworks::Networks` (`max_values`: None, `max_size`: None, mode: `Measured`)
fn update_network_block_distance() -> Weight {
// Proof Size summary in bytes:
// Measured: `294`