Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions cumulus/parachains/runtimes/assets/asset-hub-westend/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -101,12 +101,22 @@ bp-asset-hub-rococo = { workspace = true }
bp-asset-hub-westend = { workspace = true }
bp-bridge-hub-rococo = { workspace = true }
bp-bridge-hub-westend = { workspace = true }
bp-header-chain = { workspace = true }
bp-messages = { workspace = true }
bp-runtime = { workspace = true }
bridge-hub-common = { workspace = true }
Comment thread
bkontur marked this conversation as resolved.
pallet-bridge-messages = { workspace = true }
pallet-bridge-relayers = { workspace = true }
pallet-xcm-bridge = { workspace = true }
pallet-xcm-bridge-router = { workspace = true }
snowbridge-router-primitives = { workspace = true }

[dev-dependencies]
asset-test-utils = { workspace = true, default-features = true }
bp-xcm-bridge = { workspace = true }
bridge-hub-test-utils = { workspace = true, default-features = true }
bridge-runtime-common = { features = ["integrity-test"], workspace = true }
pallet-bridge-relayers = { features = ["integrity-test"], workspace = true }
parachains-runtimes-test-utils = { workspace = true, default-features = true }

[build-dependencies]
Expand All @@ -116,6 +126,8 @@ substrate-wasm-builder = { optional = true, workspace = true, default-features =
default = ["std"]
runtime-benchmarks = [
"assets-common/runtime-benchmarks",
"bridge-hub-common/runtime-benchmarks",
"bridge-runtime-common/runtime-benchmarks",
"cumulus-pallet-parachain-system/runtime-benchmarks",
"cumulus-pallet-session-benchmarking/runtime-benchmarks",
"cumulus-pallet-weight-reclaim/runtime-benchmarks",
Expand All @@ -133,6 +145,8 @@ runtime-benchmarks = [
"pallet-assets-freezer/runtime-benchmarks",
"pallet-assets/runtime-benchmarks",
"pallet-balances/runtime-benchmarks",
"pallet-bridge-messages/runtime-benchmarks",
"pallet-bridge-relayers/runtime-benchmarks",
"pallet-collator-selection/runtime-benchmarks",
"pallet-message-queue/runtime-benchmarks",
"pallet-migrations/runtime-benchmarks",
Expand All @@ -148,6 +162,7 @@ runtime-benchmarks = [
"pallet-utility/runtime-benchmarks",
"pallet-xcm-benchmarks/runtime-benchmarks",
"pallet-xcm-bridge-router/runtime-benchmarks",
"pallet-xcm-bridge/runtime-benchmarks",
"pallet-xcm/runtime-benchmarks",
"parachains-common/runtime-benchmarks",
"polkadot-parachain-primitives/runtime-benchmarks",
Expand Down Expand Up @@ -178,6 +193,8 @@ try-runtime = [
"pallet-aura/try-runtime",
"pallet-authorship/try-runtime",
"pallet-balances/try-runtime",
"pallet-bridge-messages/try-runtime",
"pallet-bridge-relayers/try-runtime",
"pallet-collator-selection/try-runtime",
"pallet-message-queue/try-runtime",
"pallet-migrations/try-runtime",
Expand All @@ -193,6 +210,7 @@ try-runtime = [
"pallet-uniques/try-runtime",
"pallet-utility/try-runtime",
"pallet-xcm-bridge-router/try-runtime",
"pallet-xcm-bridge/try-runtime",
"pallet-xcm/try-runtime",
"parachain-info/try-runtime",
"polkadot-runtime-common/try-runtime",
Expand All @@ -204,7 +222,12 @@ std = [
"bp-asset-hub-westend/std",
"bp-bridge-hub-rococo/std",
"bp-bridge-hub-westend/std",
"bp-header-chain/std",
"bp-messages/std",
"bp-runtime/std",
"bp-xcm-bridge/std",
"bridge-hub-common/std",
"bridge-runtime-common/std",
"codec/std",
"cumulus-pallet-aura-ext/std",
"cumulus-pallet-parachain-system/std",
Expand Down Expand Up @@ -233,6 +256,8 @@ std = [
"pallet-aura/std",
"pallet-authorship/std",
"pallet-balances/std",
"pallet-bridge-messages/std",
"pallet-bridge-relayers/std",
"pallet-collator-selection/std",
"pallet-message-queue/std",
"pallet-migrations/std",
Expand All @@ -251,6 +276,7 @@ std = [
"pallet-utility/std",
"pallet-xcm-benchmarks?/std",
"pallet-xcm-bridge-router/std",
"pallet-xcm-bridge/std",
"pallet-xcm/std",
"parachain-info/std",
"parachains-common/std",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Copyright (C) Parity Technologies (UK) Ltd.
// This file is part of Cumulus.

// Cumulus is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.

// Cumulus is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License
// along with Cumulus. If not, see <http://www.gnu.org/licenses/>.

//! Bridge definitions that can be used by multiple bridges.
use super::{weights, AccountId, Balance, Balances, BlockNumber, Runtime, RuntimeEvent};

frame_support::parameter_types! {
pub storage RequiredStakeForStakeAndSlash: Balance = 1_000_000;
pub const RelayerStakeLease: u32 = 8;
pub const RelayerStakeReserveId: [u8; 8] = *b"brdgrlrs";
pub storage DeliveryRewardInBalance: u64 = 1_000_000;
}

/// Allows collect and claim rewards for the relayers
pub type BridgeRelayersInstance = pallet_bridge_relayers::Instance1;
impl pallet_bridge_relayers::Config<BridgeRelayersInstance> for Runtime {
type RuntimeEvent = RuntimeEvent;
type Reward = Balance;
type PaymentProcedure =
pallet_bridge_relayers::PayRewardFromAccount<Balances, AccountId, Self::LaneId>;
type StakeAndSlash = pallet_bridge_relayers::StakeAndSlashNamed<
AccountId,
BlockNumber,
Balances,
RelayerStakeReserveId,
RequiredStakeForStakeAndSlash,
RelayerStakeLease,
>;
type WeightInfo = weights::pallet_bridge_relayers::WeightInfo<Runtime>;
type LaneId = bp_messages::HashedLaneId;
}
Loading