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

feat(storage): make snapshots non-optional in provider factory #6344

Merged

Conversation

shekhirin
Copy link
Collaborator

@shekhirin shekhirin commented Feb 2, 2024

Snapshots are becoming the integral part of querying any data from Reth node (from both inside our codebase and outside using the external process DB access): we store headers, transactions and receipts in snapshots, and want to make the way users access data abstracted away from the notion of MDBX/static file storage.

This PR makes SnapshotProvider in ProviderFactory non-optional, meaning that to initialize a provider factory you'll need to specify a path to the snapshots directory.

@shekhirin shekhirin changed the title refactor(storage): make snapshot provider non-optional in provider fa… refactor(storage): make snapshots non-optional in provider factory Feb 2, 2024
@shekhirin shekhirin force-pushed the alexey/provider-factory-snapshots-provider branch from 28f20d6 to cf69ea9 Compare February 2, 2024 13:54
@shekhirin shekhirin added C-enhancement New feature or request A-db Related to the database A-static-files Related to static files labels Feb 2, 2024
@shekhirin shekhirin changed the title refactor(storage): make snapshots non-optional in provider factory feat(storage): make snapshots non-optional in provider factory Feb 2, 2024
@shekhirin shekhirin marked this pull request as ready for review February 2, 2024 15:48
Copy link
Member

@gakonst gakonst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good w me would love if we could maybe always have the snapshots argument default to the value provided right now explicitly, since db & snapshots are under same datadir atm. but that might change in the future if mounting from a separate drive, i guess

@shekhirin shekhirin merged commit af32e85 into feat/static-files Feb 2, 2024
24 checks passed
@shekhirin shekhirin deleted the alexey/provider-factory-snapshots-provider branch February 2, 2024 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-db Related to the database A-static-files Related to static files C-enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants