dusk-network / rusk

The reference Dusk platform implementation and tools
Mozilla Public License 2.0
156 stars 59 forks source link

consensus: Rolling Finality: implement vote-accumulation quorum #1187

Open fed-franz opened 9 months ago

fed-franz commented 9 months ago

Summary

As described in #1118, the new consensus protocol will use a "naive" definition of rolling finality: after N Attested blocks, we finalize all previous non-finalized blocks.

This approach, while simple, could effectively ensure blocks finalized by the rolling finality won't be replaced with overwhelming probability. However, since this has not been yet demonstrated, and could turn to be wrong, we should evaluate in the future a different approach. This is the original proposal for rolling finality: instead of counting blocks, we count the cumulative weight of Provisioner's votes for blocks added on top of a non-final block.

Detailed Description

As per the original definition in #1118:

If, at a specific block H (where FINALIZED < H < TIP), the sum^1 of stakes reaches 67% of the total stake, block H is considered final.

(also see here)

goshawk-3 commented 9 months ago

the new consensus protocol will use a "naive" definition of rolling finality: after N Attested blocks, we finalize all previous non-finalized blocks.

Do you mean N Attested Blocks in a row or not?

Let's assume that N=3

Example_1:

Block 1 - Final Block 2 - Accepted Block 3 - Attested Block 4 - Accepted Block 5 - Attested Block 6 - Accepted Block 7- Attested

Question: Would we consider any of the blocks after Block 1 a Final? @fed-franz

fed-franz commented 9 months ago

the new consensus protocol will use a "naive" definition of rolling finality: after N Attested blocks, we finalize all previous non-finalized blocks.

Do you mean N Attested Blocks in a row or not?

Let's assume that N=3

Example_1:

Block 1 - Final Block 2 - Accepted Block 3 - Attested Block 4 - Accepted Block 5 - Attested Block 6 - Accepted Block 7- Attested

Question: Would we consider any of the blocks after Block 1 a Final? @fed-franz

N in a row.

PS: please note this is the issue for the "improved" version

fed-franz commented 8 months ago

Adding a couple of sidenotes for improving the current Rolling Finality:

autholykos commented 6 months ago

Before being able to work on this, specs need to be finalized

HDauven commented 4 months ago

@fed-franz @goshawk-3 @herr-seppia is this still relevant?

herr-seppia commented 4 months ago

@fed-franz @goshawk-3 @herr-seppia is this still relevant?

Probably not, but we should close it only when superseded by a new tracking issue explaining our direction on the topic

fed-franz commented 4 months ago

I think we should keep it around, if not here, somewhere else, as a reminder of at least evaluate a more "meaningful" rolling finality design. Once the block-accumulation based rolling finality is shown to be secure as is, we can make this obsolete (assuming this solution is by any means more complex)