Change the Config of the MaxRococoNum Slot from a Constant to a Storage function (#7217)
* set MaxPermanentSlots and MaxTemporarySlots with a extrinsic instead of a constant * delete the MaxPermanentSlots and MaxTemporarySlots constants from config on Rococo and Westend * migration code for assigned slots * remove getters * little refactor * set values in the GenesisConfig * refactor in the migration, adding it in the rococo runtime * refactor: fmt * Minor fix * pre_upgrade check * add migration to mod v1 * Logs following Substrate#12873 * fix: current storage version set to 1 * use enact when try-runtime * Vec seems to be missing * feature gate import * fix as per #13993 * address comments Co-authored-by:Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * address comments Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * benchmarking for assign_perm_parachain_slot extrinsic * benchmark all the extrinsics of the pallet * cargo fmt for assigned slots * migration added for westend * licence in benchmarking file * BuildGenesisConfig * assigned_slots default in genesis * cargo fmt * assigned_slots fix tests config * cargo fmt * fix benchmarking compile error * fix benchmarking imports * benchmark worst case scenario for validation code and head data * add assigned_slots in frame_benchmarking on Rococo and Westend * modify values for para_id in benchmarking * delete the assigned_slots in westend frame_benchmarking * fix benchmarkings and add it to westend * cargo fmt * ".git/.scripts/commands/bench/bench.sh" --subcommand=runtime --runtime=rococo --target_dir=polkadot --pallet=runtime_common::assigned_slots * ".git/.scripts/commands/bench/bench.sh" --subcommand=runtime --runtime=westend --target_dir=polkadot --pallet=runtime_common::assigned_slots * use generated weights in assigned_slots pallet * small changes in set_max_permanent_slots and set_max_temporary_slots * revert last commit * address some comments * wrap migration with VersionCheckedMigrateToV1 * add experimental feature in pallet, and assers in post_upgrade migration * clean warnings * clean unnecesary experimental flag * small typo in comments * cargo fmt * small comments fixes --------- Co-authored-by:
al3mart <11448715+al3mart@users.noreply.github.com> Co-authored-by:
Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by: command-bot <>
Showing
- polkadot/node/service/src/chain_spec.rs 4 additions, 0 deletionspolkadot/node/service/src/chain_spec.rs
- polkadot/runtime/common/Cargo.toml 3 additions, 0 deletionspolkadot/runtime/common/Cargo.toml
- polkadot/runtime/common/src/assigned_slots/benchmarking.rs 160 additions, 0 deletionspolkadot/runtime/common/src/assigned_slots/benchmarking.rs
- polkadot/runtime/common/src/assigned_slots/migration.rs 77 additions, 0 deletionspolkadot/runtime/common/src/assigned_slots/migration.rs
- polkadot/runtime/common/src/assigned_slots/mod.rs 169 additions, 33 deletionspolkadot/runtime/common/src/assigned_slots/mod.rs
- polkadot/runtime/rococo/Cargo.toml 1 addition, 1 deletionpolkadot/runtime/rococo/Cargo.toml
- polkadot/runtime/rococo/src/lib.rs 4 additions, 5 deletionspolkadot/runtime/rococo/src/lib.rs
- polkadot/runtime/rococo/src/weights/mod.rs 1 addition, 0 deletionspolkadot/runtime/rococo/src/weights/mod.rs
- polkadot/runtime/rococo/src/weights/runtime_common_assigned_slots.rs 151 additions, 0 deletions...ntime/rococo/src/weights/runtime_common_assigned_slots.rs
- polkadot/runtime/westend/Cargo.toml 1 addition, 1 deletionpolkadot/runtime/westend/Cargo.toml
- polkadot/runtime/westend/src/lib.rs 4 additions, 5 deletionspolkadot/runtime/westend/src/lib.rs
- polkadot/runtime/westend/src/weights/mod.rs 1 addition, 0 deletionspolkadot/runtime/westend/src/weights/mod.rs
- polkadot/runtime/westend/src/weights/runtime_common_assigned_slots.rs 151 additions, 0 deletions...time/westend/src/weights/runtime_common_assigned_slots.rs
Please register or sign in to comment