-
Notifications
You must be signed in to change notification settings - Fork 46
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
[sidechain] consensus (fork mitigation) #345
Comments
It has to be option 1 IMO. The problem you describe just puts a practical lower limit to the block time. We have to ensure that in 99% of all cases, the network delay is short enough for sequential block production. In contrast to non-TEE blockchain consensus, our sidechains will only need a handful of validators, so I believe the network delay is pretty much controllable within practical limits - to a sufficient probability at least |
status? can we close this? |
Not really covered yet. Only happy flow implemented. |
@clangenb and I had a discussion about this issue, since I started to think about it in more detail. I'll document the essence of our discussion here. I think it will be necessary to have another dedicated meeting, with @clangenb and @brenzi . Identifying the ordering of blocksWhen we detect a fork, we need to know the ordering of the blocks that we received. Since the block number will be the same for two competing blocks, we will probably have to resort to the timestamp to determine the ordering. Rollback mechanismsIn the case where we need to rollback changes, we face a couple of challenges:
FinalityThe concept of finality emerged in our discussion in order to define how far into the past we detect and correct forks. @clangenb mentioned, that the parentchain finalizes sidechain blocks. However, it is not clear to me how the finalization is affected by a sidechain fork. Also we then still have the issue of a fork happening right at the boundary where a parentchain block is produced. This led us to discuss if we could re-use and adapt the substrate/Polkadot consensus algorithm, GRANDPA, to our needs in the sidechain. Regardless of whether we decide to use GRANDPA or not, we must have a clear definition of finality in our sidechain in order to properly devise a solution for potential forks. |
Closed - any further specification and implementation will be done through the epic #685 |
I have been thinking about sidechain consensus. Although we trust the workers, there are still certain scenarios that must be considered.
Latency of gossiped block
The current block author gossips a valid block close to the end or after his production slot N.
Scenario:
Effect:
Now there are two options for the workers that receive block N+1 before 1:
Option 1 implications
Potential Attacks:
Potential Mitigation:
Option 2 implications:
I don't actually think that this is an option, it has too many disadvantages.
The text was updated successfully, but these errors were encountered: