Skip to content
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

slot-based-collator: improve relay chain fork selection #4547

Open
Tracked by #1829
sandreim opened this issue May 23, 2024 · 1 comment
Open
Tracked by #1829

slot-based-collator: improve relay chain fork selection #4547

sandreim opened this issue May 23, 2024 · 1 comment
Labels
I2-bug The node fails to follow expected behavior. I9-optimisation An enhancement to provide better overall performance in terms of time-to-completion for a task. T9-cumulus This PR/Issue is related to cumulus.

Comments

@sandreim
Copy link
Contributor

Long duration testing has revealed that some times we are using a relay parent on a fork that will be discarded later on by the relay chain. This happens because we always pick the relay parent as soon as we import RCB, but due to network latencies the best RCB might actually arrive after that. This results in missing all of the 3 slots.

Offline discussions revealed some options to improve the situation with some tradeoffs:

  • use relay parent at best RCB - 1 but tradeoff 6s of extra delay in XCM DMP/HRMP messages processing
  • offset parachain block production by 1-2s after RCB slot (this seemed to not actually work in tests, but no deep dive was done)
  • build on all forks - tradeoff multiplied load of relay chain validators and collator by amount of forks

On the testnet this didn't seem like a big problem as these block time spikes were rare, but on main net the issue could become more problematic.

@sandreim sandreim added I9-optimisation An enhancement to provide better overall performance in terms of time-to-completion for a task. I2-bug The node fails to follow expected behavior. T9-cumulus This PR/Issue is related to cumulus. labels May 23, 2024
@burdges
Copy link

burdges commented May 30, 2024

Afaik the first two sound fine. And the second sounds wise anyways.

this seemed to not actually work in tests, but no deep dive was done

This could be various things, but maybe just some timing things not set everywhere?

tradeoff multiplied load of relay chain validators and collator by amount of forks

We changed how collators learn of parachain blocks, right? This could magnify somewhat if they learned from other collators. If they learn from the realy chain then everything is fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I2-bug The node fails to follow expected behavior. I9-optimisation An enhancement to provide better overall performance in terms of time-to-completion for a task. T9-cumulus This PR/Issue is related to cumulus.
Projects
None yet
Development

No branches or pull requests

2 participants