[doc] Example MBM pallet (#2119)

## Basic example showcasing a migration using the MBM framework

This PR has been built on top of
https://github.com/paritytech/polkadot-sdk/pull/1781 and adds two new
example crates to the `examples` pallet

### Changes Made:

Added the `pallet-example-mbm` crate: This crate provides a minimal
example of a pallet that uses MBM. It showcases a storage migration
where values are migrated from a `u32` to a `u64`.

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Liam Aharon <liam.aharon@hotmail.com>
This commit is contained in:
Juan Girini
2024-04-04 13:47:24 +02:00
committed by GitHub
parent 0ef37c7540
commit bcb4d137c9
17 changed files with 686 additions and 11 deletions
+6
View File
@@ -320,6 +320,8 @@ impl pallet_example_tasks::Config for Runtime {
type WeightInfo = pallet_example_tasks::weights::SubstrateWeight<Runtime>;
}
impl pallet_example_mbm::Config for Runtime {}
impl pallet_utility::Config for Runtime {
type RuntimeEvent = RuntimeEvent;
type RuntimeCall = RuntimeCall;
@@ -2439,6 +2441,9 @@ mod runtime {
#[runtime::pallet_index(77)]
pub type SkipFeelessPayment = pallet_skip_feeless_payment;
#[runtime::pallet_index(78)]
pub type PalletExampleMbms = pallet_example_mbm;
}
/// The address format for describing accounts.
@@ -2597,6 +2602,7 @@ mod benches {
[pallet_whitelist, Whitelist]
[pallet_tx_pause, TxPause]
[pallet_safe_mode, SafeMode]
[pallet_example_mbm, PalletExampleMbms]
);
}