Skip to content

Commit 72e64a3

Browse files
authored
Decrease number of GRANDPA authorities in Polkadot-like chains from 100_000 to 2_048 (#1852)
* decrease number of GRANDPA authorities in Polkadot-like chains from 100_000 to 2048 * spelling
1 parent d60a331 commit 72e64a3

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

primitives/chain-rococo/src/lib.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,4 @@ pub const WITH_ROCOCO_GRANDPA_PALLET_NAME: &str = "BridgeRococoGrandpa";
4242
/// reserve.
4343
pub const MAX_NESTED_PARACHAIN_HEAD_DATA_SIZE: u32 = 128;
4444

45-
/// Maximal number of GRANDPA authorities at Rococo.
46-
///
47-
/// Corresponds to the `MaxAuthorities` constant value from the Rococo runtime configuration.
48-
pub const MAX_AUTHORITIES_COUNT: u32 = 100_000;
49-
5045
decl_bridge_finality_runtime_apis!(rococo);

primitives/chain-westend/src/lib.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,6 @@ pub const WITH_WESTEND_GRANDPA_PALLET_NAME: &str = "BridgeWestendGrandpa";
6363
/// Name of the With-Westend parachains bridge pallet instance that is deployed at bridged chains.
6464
pub const WITH_WESTEND_BRIDGE_PARAS_PALLET_NAME: &str = "BridgeWestendParachains";
6565

66-
/// Maximal number of GRANDPA authorities at Westend.
67-
///
68-
/// Corresponds to the `MaxAuthorities` constant value from the Westend runtime configuration.
69-
pub const MAX_AUTHORITIES_COUNT: u32 = 100_000;
70-
7166
/// Maximal SCALE-encoded size of parachains headers that are stored at Westend `Paras` pallet.
7267
///
7368
/// It includes the block number and state root, so it shall be near 40 bytes, but let's have some

primitives/polkadot-core/src/lib.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,16 @@ pub use sp_runtime::{traits::Convert, Perbill};
4343

4444
pub mod parachains;
4545

46+
/// Maximal number of GRANDPA authorities at Polkadot-like chains.
47+
///
48+
/// Ideally, we would set it to the value of `MaxAuthorities` constant from bridged runtime
49+
/// configurations. But right now it is set to the `100_000`, which makes PoV size for
50+
/// our bridge hub parachains huge. So let's stick to the real-world value here.
51+
///
52+
/// Right now both Kusama and Polkadot aim to have around 1000 validators. Let's be safe here and
53+
/// take twice as much here.
54+
pub const MAX_AUTHORITIES_COUNT: u32 = 2_048;
55+
4656
/// Number of extra bytes (excluding size of storage value itself) of storage proof, built at
4757
/// Polkadot-like chain. This mostly depends on number of entries in the storage trie.
4858
/// Some reserve is reserved to account future chain growth.

0 commit comments

Comments
 (0)