Trait cumulus_pallet_xcmp_queue::pallet::Config
source · pub trait Config: Config {
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type ChannelInfo: GetChannelInfo;
type VersionWrapper: WrapVersion;
type XcmpQueue: EnqueueMessage<ParaId>;
type MaxInboundSuspended: Get<u32>;
type MaxActiveOutboundChannels: Get<u32>;
type MaxPageSize: Get<u32>;
type ControllerOrigin: EnsureOrigin<Self::RuntimeOrigin>;
type ControllerOriginConverter: ConvertOrigin<Self::RuntimeOrigin>;
type PriceForSiblingDelivery: PriceForMessageDelivery<Id = ParaId>;
type WeightInfo: WeightInfo;
}
Expand description
Configuration trait of this pallet.
The main purpose of this trait is to act as an interface between this pallet and the runtime in which it is embedded in. A type, function, or constant in this trait is essentially left to be configured by the runtime that includes this pallet.
Consequently, a runtime that wants to include this pallet must implement this trait.
Required Associated Types§
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
sourcetype ChannelInfo: GetChannelInfo
type ChannelInfo: GetChannelInfo
Information on the available XCMP channels.
sourcetype VersionWrapper: WrapVersion
type VersionWrapper: WrapVersion
Means of converting an Xcm
into a VersionedXcm
.
sourcetype XcmpQueue: EnqueueMessage<ParaId>
type XcmpQueue: EnqueueMessage<ParaId>
Enqueue an inbound horizontal message for later processing.
This defines the maximal message length via crate::MaxXcmpMessageLenOf
. The pallet
assumes that this hook will eventually process all the pushed messages.
sourcetype MaxInboundSuspended: Get<u32>
type MaxInboundSuspended: Get<u32>
The maximum number of inbound XCMP channels that can be suspended simultaneously.
Any further channel suspensions will fail and messages may get dropped without further
notice. Choosing a high value (1000) is okay; the trade-off that is described in
InboundXcmpSuspended
still applies at that scale.
sourcetype MaxActiveOutboundChannels: Get<u32>
type MaxActiveOutboundChannels: Get<u32>
Maximal number of outbound XCMP channels that can have messages queued at the same time.
If this is reached, then no further messages can be sent to channels that do not yet
have a message queued. This should be set to the expected maximum of outbound channels
which is determined by Self::ChannelInfo
. It is important to set this large enough,
since otherwise the congestion control protocol will not work as intended and messages
may be dropped. This value increases the PoV and should therefore not be picked too
high. Governance needs to pay attention to not open more channels than this value.
sourcetype MaxPageSize: Get<u32>
type MaxPageSize: Get<u32>
The maximal page size for HRMP message pages.
A lower limit can be set dynamically, but this is the hard-limit for the PoV worst case benchmarking. The limit for the size of a message is slightly below this, since some overhead is incurred for encoding the format.
sourcetype ControllerOrigin: EnsureOrigin<Self::RuntimeOrigin>
type ControllerOrigin: EnsureOrigin<Self::RuntimeOrigin>
The origin that is allowed to resume or suspend the XCMP queue.
sourcetype ControllerOriginConverter: ConvertOrigin<Self::RuntimeOrigin>
type ControllerOriginConverter: ConvertOrigin<Self::RuntimeOrigin>
The conversion function used to attempt to convert an XCM Location
origin to a
superuser origin.
sourcetype PriceForSiblingDelivery: PriceForMessageDelivery<Id = ParaId>
type PriceForSiblingDelivery: PriceForMessageDelivery<Id = ParaId>
The price for delivering an XCM to a sibling parachain destination.
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
The weight information of this pallet.