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

node: refactorings related to NodeSettings and stages #1890

Merged
merged 10 commits into from
Mar 11, 2024

Conversation

battlmonstr
Copy link
Contributor

@battlmonstr battlmonstr commented Mar 7, 2024

This is a step to improve the node module structure. It aims to untie the node/stagedsync/stages subfolder from depending on the node parent folder. When stages don't depend on silkworm_node they can be moved to other places freely. Stages depend just on core, infra and db.

  • pass preverified_hashes_height to BodiesStage to not depend on node/common in stages
  • move BlockBodyForStorage to core/types so that snapshots and db can use it
  • refactor ResourceUsageLog to not depend on NodeSettings and move it to node
  • move stages test, because it uses multiple stages and still relies on NodeSettings
  • remove temp_chain_data_node_settings dependency in stages
  • rename node_settings file
  • move base stage to db (to make possible implement stages in other modules and not depend on node)
  • silkworm_stages library target (to isolate it from node)
  • fix deps.py

@battlmonstr battlmonstr requested a review from canepat March 7, 2024 15:55
@battlmonstr battlmonstr force-pushed the pr/stagedsync_refac_2 branch 2 times, most recently from 12bdcb5 to a30a26b Compare March 8, 2024 07:45
@battlmonstr battlmonstr marked this pull request as ready for review March 8, 2024 13:57
@canepat canepat added the maintenance Some maintenance work (fix, refactor, rename, test...) label Mar 11, 2024
@canepat canepat merged commit 9f49564 into master Mar 11, 2024
4 checks passed
@canepat canepat deleted the pr/stagedsync_refac_2 branch March 11, 2024 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Some maintenance work (fix, refactor, rename, test...)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants