19 breaking releases

0.22.0 Apr 4, 2025
0.21.0 Jan 29, 2025
0.20.0 Jan 14, 2025
0.18.0 Oct 1, 2024
0.0.0 Nov 14, 2022

#974 in Magic Beans

Download history 44/week @ 2024-12-22 28/week @ 2024-12-29 74/week @ 2025-01-05 200/week @ 2025-01-12 168/week @ 2025-01-19 268/week @ 2025-01-26 255/week @ 2025-02-02 271/week @ 2025-02-09 164/week @ 2025-02-16 169/week @ 2025-02-23 118/week @ 2025-03-02 111/week @ 2025-03-09 132/week @ 2025-03-16 270/week @ 2025-03-23 288/week @ 2025-03-30 448/week @ 2025-04-06

1,157 downloads per month
Used in 11 crates (4 directly)

GPL-3.0-or-later…

1.5MB
21K SLoC

The relay-chain provided consensus algorithm for parachains.

This is the simplest consensus algorithm you can use when developing a parachain. It is a permission-less consensus algorithm that doesn't require any staking or similar to join as a collator. In this algorithm the consensus is provided by the relay-chain. This works in the following way.

  1. Each node that sees itself as a collator is free to build a parachain candidate.

  2. This parachain candidate is send to the parachain validators that are part of the relay chain.

  3. The parachain validators validate at most X different parachain candidates, where X is the total number of parachain validators.

  4. The parachain candidate that is backed by the most validators is chosen by the relay-chain block producer to be added as backed candidate on chain.

  5. After the parachain candidate got backed and included, all collators start at 1.

Dependencies

~99–135MB
~2.5M SLoC