1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
pub use pallet_bridge_messages::Instance1 as WithPangolinMessages;
use crate::*;
use bp_messages::MessageNonce;
use bp_runtime::{ChainId, PANGOLIN_CHAIN_ID};
use pallet_bridge_messages::Config;
use pallet_fee_market::s2s::{
FeeMarketMessageAcceptedHandler, FeeMarketMessageConfirmedHandler, FeeMarketPayment,
};
frame_support::parameter_types! {
pub const BridgedChainId: ChainId = PANGOLIN_CHAIN_ID;
pub const MaxMessagesToPruneAtOnce: MessageNonce = 8;
pub const MaxUnconfirmedMessagesAtInboundLane: MessageNonce =
bp_pangolin::MAX_UNCONFIRMED_MESSAGES_IN_CONFIRMATION_TX;
pub const MaxUnrewardedRelayerEntriesAtInboundLane: MessageNonce =
bp_pangolin::MAX_UNREWARDED_RELAYERS_IN_CONFIRMATION_TX;
}
impl Config<WithPangolinMessages> for Runtime {
type AccountIdConverter = bp_pangoro::AccountIdConverter;
type BridgedChainId = BridgedChainId;
type Event = Event;
type InboundMessageFee = bp_pangolin::Balance;
type InboundPayload = bm_pangolin::FromPangolinMessagePayload;
type InboundRelayer = bp_pangolin::AccountId;
type LaneMessageVerifier = bm_pangolin::ToPangolinMessageVerifier;
type MaxMessagesToPruneAtOnce = MaxMessagesToPruneAtOnce;
type MaxUnconfirmedMessagesAtInboundLane = MaxUnconfirmedMessagesAtInboundLane;
type MaxUnrewardedRelayerEntriesAtInboundLane = MaxUnrewardedRelayerEntriesAtInboundLane;
type MessageDeliveryAndDispatchPayment = FeeMarketPayment<Self, WithPangolinFeeMarket, Ring>;
type MessageDispatch = bm_pangolin::FromPangolinMessageDispatch;
type OnDeliveryConfirmed = FeeMarketMessageConfirmedHandler<Self, WithPangolinFeeMarket>;
type OnMessageAccepted = FeeMarketMessageAcceptedHandler<Self, WithPangolinFeeMarket>;
type OutboundMessageFee = bp_pangoro::Balance;
type OutboundPayload = bm_pangolin::ToPangolinMessagePayload;
type Parameter = bm_pangolin::PangoroToPangolinMessagesParameter;
type SourceHeaderChain = bm_pangolin::Pangolin;
type TargetHeaderChain = bm_pangolin::Pangolin;
type WeightInfo = ();
}