Trait pallet_circuit::pallet::Config
source · pub trait Config: Config {
Show 18 associated items
type SelfAccountId: Get<Self::AccountId>;
type SelfGatewayId: Get<[u8; 4]>;
type SelfParaId: Get<u32>;
type XtxTimeoutDefault: Get<BlockNumberFor<Self>>;
type XtxTimeoutCheckInterval: Get<BlockNumberFor<Self>>;
type SFXBiddingPeriod: Get<BlockNumberFor<Self>>;
type DeletionQueueLimit: Get<u32>;
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type WeightInfo: WeightInfo;
type Balances: Inspect<Self::AccountId> + Mutate<Self::AccountId>;
type Currency: Currency<Self::AccountId>;
type Xdns: Xdns<Self, BalanceOf<Self>>;
type Attesters: AttestersWriteApi<Self::AccountId, DispatchError> + AttestersReadApi<Self::AccountId, BalanceOf<Self>, BlockNumberFor<Self>>;
type Executors: Executors<Self, BalanceOf<Self>>;
type AccountManager: AccountManager<Self::AccountId, BalanceOf<Self>, Self::Hash, BlockNumberFor<Self>, u32>;
type Portal: Portal<Self>;
type SignalQueueDepth: Get<u32>;
type TreasuryAccounts: TreasuryAccountProvider<Self::AccountId>;
}
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. This pallet’s configuration trait
Required Associated Types§
sourcetype SelfAccountId: Get<Self::AccountId>
type SelfAccountId: Get<Self::AccountId>
The Circuit’s account id
sourcetype SelfGatewayId: Get<[u8; 4]>
type SelfGatewayId: Get<[u8; 4]>
The Circuit’s self gateway id
sourcetype SelfParaId: Get<u32>
type SelfParaId: Get<u32>
The Circuit’s self parachain id
sourcetype XtxTimeoutDefault: Get<BlockNumberFor<Self>>
type XtxTimeoutDefault: Get<BlockNumberFor<Self>>
The Circuit’s Default Xtx timeout
sourcetype XtxTimeoutCheckInterval: Get<BlockNumberFor<Self>>
type XtxTimeoutCheckInterval: Get<BlockNumberFor<Self>>
The Circuit’s Xtx timeout check interval
sourcetype SFXBiddingPeriod: Get<BlockNumberFor<Self>>
type SFXBiddingPeriod: Get<BlockNumberFor<Self>>
The Circuit’s SFX Bidding Period
sourcetype DeletionQueueLimit: Get<u32>
type DeletionQueueLimit: Get<u32>
The Circuit’s deletion queue limit - preventing potential delay when queue is too long in on_initialize
sourcetype RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
The overarching event type.
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Weight information for extrinsics in this pallet.
sourcetype Balances: Inspect<Self::AccountId> + Mutate<Self::AccountId>
type Balances: Inspect<Self::AccountId> + Mutate<Self::AccountId>
A type that provides inspection and mutation to some fungible assets
type Currency: Currency<Self::AccountId>
type Attesters: AttestersWriteApi<Self::AccountId, DispatchError> + AttestersReadApi<Self::AccountId, BalanceOf<Self>, BlockNumberFor<Self>>
type Executors: Executors<Self, BalanceOf<Self>>
sourcetype AccountManager: AccountManager<Self::AccountId, BalanceOf<Self>, Self::Hash, BlockNumberFor<Self>, u32>
type AccountManager: AccountManager<Self::AccountId, BalanceOf<Self>, Self::Hash, BlockNumberFor<Self>, u32>
A type that provides access to AccountManager
sourcetype SignalQueueDepth: Get<u32>
type SignalQueueDepth: Get<u32>
The maximum number of signals that can be queued for handling.
When a signal from 3vm is requested, we add it to the queue to be handled by on_initialize
This allows us to process the highest priority and mitigate any race conditions from additional steps.
The reasons for limiting the queue depth are:
- The queue is in storage in order to be persistent between blocks. We want to limit the amount of storage that can be consumed.
- The queue is stored in a vector and needs to be decoded as a whole when reading it at the end of each block. Longer queues take more weight to decode and hence limit the amount of items that can be deleted per block.