mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 00:37:57 +00:00
5208bed7d2
Extract `WarpSync` (and `StateSync` as part of warp sync) from `ChainSync` as independent syncing strategy called by `SyncingEngine`. Introduce `SyncingStrategy` enum as a proxy between `SyncingEngine` and specific syncing strategies. ## Limitations Gap sync is kept in `ChainSync` for now because it shares the same set of peers as block syncing implementation in `ChainSync`. Extraction of a common context responsible for peer management in syncing strategies able to run in parallel is planned for a follow-up PR. ## Further improvements A possibility of conversion of `SyncingStartegy` into a trait should be evaluated. The main stopper for this is that different strategies need to communicate different actions to `SyncingEngine` and respond to different events / provide different APIs (e.g., requesting justifications is only possible via `ChainSync` and not through `WarpSync`; `SendWarpProofRequest` action is only relevant to `WarpSync`, etc.) --------- Co-authored-by: Aaro Altonen <48052676+altonen@users.noreply.github.com>
16 lines
603 B
Plaintext
16 lines
603 B
Plaintext
# Schema: Polkadot SDK PRDoc Schema (prdoc) v1.0.0
|
|
# See doc at https://raw.githubusercontent.com/paritytech/polkadot-sdk/master/prdoc/schema_user.json
|
|
|
|
title: Extract warp sync strategy from `ChainSync`
|
|
|
|
doc:
|
|
- audience: Node Dev
|
|
description: |
|
|
`WarpSync`, and `StateSync` as the logical part of warp sync, are extracted from `ChainSync`
|
|
as independent syncing strategies. `SyncingStrategy` enum is introduced as a proxy between
|
|
`SyncingEngine` and specific strategies. `SyncingStrategy` may be replaced by a trait in a
|
|
follow-up PRs.
|
|
|
|
crates:
|
|
- name: sc-network-sync
|