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

Add force flag to TreeWorkerArgs for complete reindexing #148

Merged
merged 2 commits into from
Sep 13, 2024

Conversation

kevinrodriguez-io
Copy link

@kevinrodriguez-io kevinrodriguez-io commented Sep 12, 2024

Description

This PR introduces a new force flag to the TreeWorkerArgs struct, allowing for a complete reindex of trees from the first transaction up to the current sequence number. When the force flag is set, the backfiller skips checking gaps in cl_audits_v2, effectively ignoring existing audit data and performing a full reindex.

Changes

  • Added a force boolean flag to TreeWorkerArgs struct
  • Modified the start method in TreeWorkerArgs to use the force flag
  • Removed queries to cl_audits_v2 when force flag is set

Motivation

This change allows for a complete reindex of trees.

Notes for Reviewers

  • The main logic change is in the start method of TreeWorkerArgs
  • Pay attention to the handling of gaps when the force flag is set vs. when it's not
  • Ensure that the existing functionality is preserved when the force flag is not used

@kevinrodriguez-io kevinrodriguez-io changed the title feat: allows for a complete reindex Add force flag to TreeWorkerArgs for complete reindexing Sep 12, 2024
@kespinola kespinola merged commit 4c3f649 into rpcpool:grpc-ingest Sep 13, 2024
3 checks passed
@kespinola kespinola deleted the feat-force-noaudits branch September 13, 2024 03:28
kespinola added a commit that referenced this pull request Sep 13, 2024
* feat: allows complete reindex

* chore: allow deprecated borsh package

---------

Co-authored-by: Kevin Rodríguez <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants