mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 07:01:03 +00:00
XCM: Tools for uniquely referencing messages (#7234)
* Tools for unique topic references * Formatting * Naming * Repot into routing.rs. * More things done * Universal Exporter supports topic-as-reference * Some tests for the topic routing * More tests * Paid bridge tests * Add message ID to sending events * Formatting * fix and integrate into test nets * Move DenyThenTry and friend from Cumulus * Append SetTopic rather than prepend * Docs * Docs * Work with new ProcessMessage ID API * Formatting * Fix build * Fixes * Formatting * Update xcm/xcm-builder/src/barriers.rs Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com> * Update xcm/xcm-builder/src/routing.rs Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com> * Docs * Rename message_hash * Formatting * ".git/.scripts/commands/fmt/fmt.sh" * Rename * Another Rename * ".git/.scripts/commands/fmt/fmt.sh" * ".git/.scripts/commands/fmt/fmt.sh" * Update xcm/xcm-builder/src/routing.rs Co-authored-by: Keith Yeung <kungfukeith11@gmail.com> --------- Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com> Co-authored-by: command-bot <> Co-authored-by: Keith Yeung <kungfukeith11@gmail.com>
This commit is contained in:
@@ -41,8 +41,8 @@ use xcm_builder::{
|
||||
ChildParachainConvertsVia, ChildSystemParachainAsSuperuser,
|
||||
CurrencyAdapter as XcmCurrencyAdapter, FixedWeightBounds, IsChildSystemParachain, IsConcrete,
|
||||
MintLocation, OriginToPluralityVoice, SignedAccountId32AsNative, SignedToAccountId32,
|
||||
SovereignSignedViaLocation, TakeWeightCredit, UsingComponents, WeightInfoBounds,
|
||||
WithComputedOrigin,
|
||||
SovereignSignedViaLocation, TakeWeightCredit, TrailingSetTopicAsId, UsingComponents,
|
||||
WeightInfoBounds, WithComputedOrigin, WithUniqueTopic,
|
||||
};
|
||||
use xcm_executor::traits::WithOriginFilter;
|
||||
|
||||
@@ -115,14 +115,14 @@ parameter_types! {
|
||||
|
||||
/// The XCM router. When we want to send an XCM message, we use this type. It amalgamates all of our
|
||||
/// individual routers.
|
||||
pub type XcmRouter = (
|
||||
pub type XcmRouter = WithUniqueTopic<(
|
||||
// Only one router so far - use DMP to communicate with child parachains.
|
||||
ChildParachainRouter<
|
||||
Runtime,
|
||||
XcmPallet,
|
||||
ExponentialPrice<FeeAssetId, BaseDeliveryFee, TransactionByteFee, Dmp>,
|
||||
>,
|
||||
);
|
||||
)>;
|
||||
|
||||
parameter_types! {
|
||||
pub const Ksm: MultiAssetFilter = Wild(AllOf { fun: WildFungible, id: Concrete(TokenLocation::get()) });
|
||||
@@ -142,7 +142,7 @@ match_types! {
|
||||
}
|
||||
|
||||
/// The barriers one of which must be passed for an XCM message to be executed.
|
||||
pub type Barrier = (
|
||||
pub type Barrier = TrailingSetTopicAsId<(
|
||||
// Weight that is paid for may be consumed.
|
||||
TakeWeightCredit,
|
||||
// Expected responses are OK.
|
||||
@@ -159,7 +159,7 @@ pub type Barrier = (
|
||||
UniversalLocation,
|
||||
ConstU32<8>,
|
||||
>,
|
||||
);
|
||||
)>;
|
||||
|
||||
/// A call filter for the XCM Transact instruction. This is a temporary measure until we properly
|
||||
/// account for proof size weights.
|
||||
|
||||
Reference in New Issue
Block a user