Chain specific message lane apis (#503)

* replace generic message lane APIs with chain-specific

* moved SubstrateHeadersSyncPipeline to headers_pipeline.rs

* substrate-specific message lane trait

* Update relays/substrate/src/messages_lane.rs

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>

Co-authored-by: Hernando Castano <HCastano@users.noreply.github.com>
This commit is contained in:
Svyatoslav Nikolsky
2020-11-23 10:55:47 +03:00
committed by Bastian Köcher
parent d2ab81340a
commit 53791a1d4a
16 changed files with 309 additions and 231 deletions
+2 -4
View File
@@ -704,8 +704,7 @@ impl_runtime_apis! {
}
}
// TODO: runtime should support several chains (https://github.com/paritytech/parity-bridges-common/issues/457)
impl bp_message_lane::OutboundLaneApi<Block> for Runtime {
impl bp_millau::ToMillauOutboundLaneApi<Block> for Runtime {
fn messages_dispatch_weight(
lane: bp_message_lane::LaneId,
begin: bp_message_lane::MessageNonce,
@@ -730,8 +729,7 @@ impl_runtime_apis! {
}
}
// TODO: runtime should support several chains (https://github.com/paritytech/parity-bridges-common/issues/457)
impl bp_message_lane::InboundLaneApi<Block> for Runtime {
impl bp_millau::FromMillauInboundLaneApi<Block> for Runtime {
fn latest_received_nonce(lane: bp_message_lane::LaneId) -> bp_message_lane::MessageNonce {
BridgeMillauMessageLane::inbound_latest_received_nonce(lane)
}