mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 16:21:02 +00:00
Breakdown the Router module on Dmp, Ump, Hrmp modules (#1939)
* Guide: Split router module in guide. Now we have: DMP, UMP and Router module. * Add a glossary entry for what used to be called Router * Extract DMP * Extract UMP * Extract HRMP * Switch over to new modules * Router: goodbye sweet prince * Link to messaging overview for details. * Update missed rococo and test runtimes. * Commit destroyed by rebase changes * Don't deprecate Router but rather make it a meta-project Co-authored-by: Bernhard Schuster <bernhard@ahoi.io> * Fix typos suggestion Co-authored-by: Bernhard Schuster <bernhard@ahoi.io> * Fix repetition in the impl guide * Clarify that processed_downward_messages has the u32 type * Remove the router subdir. * Deabbreviate DMP,UMP,HRMP Co-authored-by: Bernhard Schuster <bernhard@ahoi.io>
This commit is contained in:
@@ -27,10 +27,12 @@ pub mod inclusion;
|
||||
pub mod inclusion_inherent;
|
||||
pub mod initializer;
|
||||
pub mod paras;
|
||||
pub mod router;
|
||||
pub mod scheduler;
|
||||
pub mod validity;
|
||||
pub mod origin;
|
||||
pub mod dmp;
|
||||
pub mod ump;
|
||||
pub mod hrmp;
|
||||
|
||||
pub mod runtime_api_impl;
|
||||
|
||||
@@ -40,3 +42,25 @@ mod util;
|
||||
mod mock;
|
||||
|
||||
pub use origin::{Origin, ensure_parachain};
|
||||
|
||||
/// Schedule a para to be initialized at the start of the next session with the given genesis data.
|
||||
pub fn schedule_para_initialize<T: paras::Trait>(
|
||||
id: primitives::v1::Id,
|
||||
genesis: paras::ParaGenesisArgs,
|
||||
) {
|
||||
<paras::Module<T>>::schedule_para_initialize(id, genesis);
|
||||
}
|
||||
|
||||
/// Schedule a para to be cleaned up at the start of the next session.
|
||||
pub fn schedule_para_cleanup<T>(id: primitives::v1::Id)
|
||||
where
|
||||
T: paras::Trait
|
||||
+ dmp::Trait
|
||||
+ ump::Trait
|
||||
+ hrmp::Trait,
|
||||
{
|
||||
<paras::Module<T>>::schedule_para_cleanup(id);
|
||||
<dmp::Module<T>>::schedule_para_cleanup(id);
|
||||
<ump::Module<T>>::schedule_para_cleanup(id);
|
||||
<hrmp::Module<T>>::schedule_para_cleanup(id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user