Skip to content
Unverified Commit 178e699c authored by Lech Głowiak's avatar Lech Głowiak Committed by GitHub
Browse files

Skip slot before creating inherent data providers during major sync (#5344)

# Description

Moves `create_inherent_data_provider` after checking if major sync is in
progress.

## Integration

Change is internal to sc-consensus-slots. It should be no-op unless
someone is using fork of this SDK.

## Review Notes

Motivation for this change is to avoid calling
`create_inherent_data_providers` if it's result is going to be discarded
anyway during major sync. This has potential to speed up node operations
during major sync by not calling possibly expensive
`create_inherent_data_provider`.

TODO: labels T0-node D0-simple
TODO: there is no tests for `Slots`, should I add one for this case?

# Checklist

* [x] My PR includes a detailed description as outlined in the
"Description" and its two subsections above.
* [x] My PR follows the [labeling requirements](CONTRIBUTING.md#Process)
of this project (at minimum one label for `T`
  required)
* External contributors: ask maintainers to put the right label on your
PR.
* [ ] I have made corresponding changes to the documentation (if
applicable)
* [ ] I have added tests that prove my fix is effective or that my
feature works (if applicable)
parent 91b5a49a
Pipeline #492640 waiting for manual action with stages
in 1 hour, 14 minutes, and 34 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment