-
Notifications
You must be signed in to change notification settings - Fork 74
Add async backing technical reference #1179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: staging/product-ia
Are you sure you want to change the base?
Add async backing technical reference #1179
Conversation
- still need to finalize diagrams and give better context of them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Automated style guide suggestions (1-4 of 4)
β¦tions - improved timeline graphs of inclusion pipeline
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds new documentation for Polkadot's asynchronous backing and inclusion pipeline features, explaining how rollup blocks are processed and validated in the relay chain.
- Introduces comprehensive documentation for asynchronous backing, including configuration options and visual comparisons between synchronous and asynchronous processing
- Adds a new page explaining the inclusion pipeline stages (Generation, Backing, and Inclusion)
- Updates the llms.txt index to reflect the new documentation pages
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 9 comments.
| File | Description |
|---|---|
| reference/parachains/consensus/inclusion-pipeline.md | New documentation page explaining the multi-step pipeline for rollup block processing, including Generation, Backing, and Inclusion stages |
| reference/parachains/consensus/async-backing.md | New comprehensive documentation on asynchronous backing, including governance configurations, processing diagrams, and multi-core scenarios |
| llms.txt | Updated documentation index with new page entries and incremented page count from 269 to 271 |
π‘ Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| Backing : item2, 1920, 1930 | ||
| ``` | ||
|
|
||
| Notice how `P2` starts before the backing stage of `P1` |
Copilot
AI
Nov 7, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Incomplete sentence. The sentence "Notice how P2 starts before the backing stage of P1" appears to be cut off and should be completed or followed by additional explanation.
| Notice how `P2` starts before the backing stage of `P1` | |
| Notice how `P2` starts before the backing stage of `P1`. This illustrates the core benefit of asynchronous backing: multiple parachain blocks can be generated and begin their backing process in parallel, rather than waiting for the previous block's backing to finish. As a result, block production and validation are pipelined, increasing throughput and reducing latency across the network. |
|
|
||
| ## Synchronous VS. Asynchronous Processing | ||
|
|
||
| *in progress* |
Copilot
AI
Nov 7, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Placeholder text "in progress" should be removed or replaced with actual content before publishing.
| *in progress* | |
| Let's compare how block production and validation differ between synchronous and asynchronous processing. |
|
This is ready for feedback. I split this up into two technical reference pages
Everything is in good condition besides the section titled Additionally there are 3 empty links in
Which, I was hoping there are definition these could link to? |
brunopgalvao
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left my review. Overall I would focus on making sure the concept of async backing flows well for readers. I left some comments that can help in the direction.
|
|
||
| **Generation**: Collators *execute* their blockchain's core functionality to generate a new block, producing a [candidate receipt](), which is passed to validators selected for backing. | ||
|
|
||
| **Backing**: A subset of active validators verify if the parablock follows the state transition rules of the parachain and sign *Proof of Validity* (PoV) statements that can have a positive or negative outcome. With enough positive statements, the block is backed and included in the relay chain, but is still pending approval. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| **Backing**: A subset of active validators verify if the parablock follows the state transition rules of the parachain and sign *Proof of Validity* (PoV) statements that can have a positive or negative outcome. With enough positive statements, the block is backed and included in the relay chain, but is still pending approval. | |
| **Backing**: A subset of active validators verify the parablock and sign validity statements (backing statements) about the Proof of Validity (PoV) statements that can have a positive or negative outcome. With enough positive statements, the block is backed and included in the relay chain, but is still pending approval. |
PoV (Proof of Validity) is the state transition proof that collators produce, not what validators sign. Validators sign "validity statements" or "backing statements" about the PoV.
| classDef nobox fill:none,stroke:none,color:inherit; | ||
| ``` | ||
| **Context**: Context of state is provided as input in order for collators and validators to build a parablocks during the generation and backing stages, respectively. This context is provided by two sources: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| **Context**: Context of state is provided as input in order for collators and validators to build a parablocks during the generation and backing stages, respectively. This context is provided by two sources: | |
| **Context**: Context of state is provided as input in order for collators and validators to build parablocks during the generation and backing stages, respectively. This context is provided by two sources: |
| Backing : item2, 1920, 1930 | ||
| ``` | ||
|
|
||
| Notice how `P2` starts before the backing stage of `P1` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| Notice how `P2` starts before the backing stage of `P1` | |
| Notice how P2 starts before the backing stage of P1 completes |
|
|
||
| Notice how `P2` starts before the backing stage of `P1` | ||
|
|
||
| In the multi-core scenario |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This heading has no explanatory text - just a diagram. Need to add context explaining what the multi-core/elastic scaling scenario demonstrates.
| categories: Polkadot Protocol | ||
| --- | ||
|
|
||
| Asynchronous backing (often shortened to ***Async Backing***) is a parachain [configuration](https://github.com/paritytech/polkadot-sdk/blob/f204e3264f945c33b4cea18a49f7232c180b07c5/polkadot/primitives/src/vstaging/mod.rs#L43) set by on-chain governance. It allows collators and validators to build *some* number of blocks ahead of the relay chain during the **generation** and **backing** stages of the [Inclusion Pipeline](/reference/parachains/consensus/inclusion-pipeline). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest a smoother introduction. Maybe something like this:
Asynchronous backing (often shortened to Async Backing) is a parachain protocol feature that
significantly improves performance, enabling parachains to produce blocks twice as fast (every 6
seconds instead of every 12 seconds) with 4x more execution time per block (2 seconds instead of 0.5
seconds).
Technically, async backing is a parachain configuration that allows collators to build new blocks on
top of unincluded segmentsβchains of parachain blocks that have not yet been fully included in the
relay chain. This decouples parachain block production from relay chain inclusion.
Without async backing (synchronous mode), collators must wait for each parablock to complete the
entire inclusion pipeline before building the next one. This tight coupling limits throughput to one
parablock every 12 seconds (every other relay block).
With async backing enabled, collators can begin building a new block as soon as the previous block
completes the generation stage, without waiting for full inclusion. This pipelining approach enables:
- Higher throughput: One parablock every 6 seconds (every relay block) instead of every 12 seconds
- Extended execution time: 2 seconds per block instead of 0.5 seconds, allowing more complex
computation - Better coretime utilization: More efficient use of allocated coretime across the network
- Elastic scaling support: The pipelining foundation needed for parachains to scale across multiple
cores
The degree of pipelining is controlled by on-chain governance through configuration parameters like
max_candidate_depth and allowed_ancestry_len.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And add links to key terms.
|
|
||
| *in progress* | ||
|
|
||
| In the synchronous scenario, both the collators and validators draw context from the relay parent of the prior parablock, which lives on the relay chain. This makes the Backing and Generation steps tightly coupled to the prior parablock completing the inclusion pipeline. As a result, one parablock can be processed every other relay block, and only `0.5` seconds are assigned for execution. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would recommend adding context here for developers who are new to Polkadot - noting that synchronous backing was the old way, and the new, better way which is baked into the protocol is asynchronous backing. Something like this:
The Polkadot-parachain protocol originally operated in synchronous mode, where both collators and validators drew context exclusively from the relay parent of the prior parablock, which lives on the relay chain. This made the Backing and Generation steps tightly coupled to the prior parablock completing the entire inclusion pipeline. As a result, one parablock could only be processed every other relay block, with just 0.5 seconds assigned for execution.
The modern protocol now uses asynchronous backing, where both collators and validators have access to /reference/parachains/consensus/inclusion-pipeline as an additional context source. The Backing and Generation steps are no longer coupled to the prior block completing the full inclusion pipeline. Instead, the prior parablock only needs to complete the generation step and be added to the Unincluded Segments before the next parablock can begin the Backing and Generation steps.
This results in one parablock being processed every relay block (instead of every other relay block), and allows for more time to execute during the Generation step (0.5s β 2s).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And add links to key terms.
| categories: Polkadot Protocol | ||
| --- | ||
|
|
||
| The mulit-step pipeline through which parablocks are processed into the Polkadot relay chain: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The inclusion pipeline is a fundamental Polkadot concept that exists independently of async backing. The current page jumps straight into technical details without explaining what it is or why it matters. We need a well-framed introduction for this page to succeed. Something like this:
The inclusion pipeline is the multi-stage process through which every parachain block (parablock) is validated and secured before being finalized in the Polkadot relay chain. This pipeline ensures that all parachain blocks meet validity requirements through progressive verification by multiple sets of validators.
The pipeline exists to provide Polkadot's security guarantees: rather than trusting a single validator group, each parablock passes through multiple validation stages with different validator sets, ensuring that invalid blocks cannot be finalized even if some validators are malicious or compromised.
Whether a parachain uses synchronous or asynchronous backing, all parablocks follow the same inclusion pipeline. The difference is in the timing: asynchronous backing allows multiple blocks to be at different stages of the pipeline simultaneously (pipelining), while synchronous backing processes one block through the entire pipeline before starting the next.
Pipeline Stages
The inclusion pipeline consists of three main stages:
[existing mermaid diagram]
π Description
Provide a clear and concise description of your changes.
π Review Preference
Choose one:
π€ AI-Ready Docs
If content changed, regenerate AI files:
python3 scripts/generate_llms.pyβ Checklist