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 tool to optimize a blockchain database #380

Merged
merged 1 commit into from
Jan 31, 2024
Merged

add tool to optimize a blockchain database #380

merged 1 commit into from
Jan 31, 2024

Conversation

arvidn
Copy link
Contributor

@arvidn arvidn commented Jan 31, 2024

testing this on my blockchain database:

peak block hash: 7a7546d1cac0270fe25bdd7bbaba0d4ed48626eb3859d39a88eb7da0f2d32aff
peak height: 4878515
dropping orphaned blocks...
removed 6574 orphaned blocks
2799635 fully compact blocks (57.39%)
analyze block table
analyze coins table
analyze hints table
vacuum into mainnet-test.db
all done!

database size

before after after/before
163018407936 152597893120 93.6 %

Copy link

Pull Request Test Coverage Report for Build 7726394687

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 84.684%

Totals Coverage Status
Change from base Build 7655434740: 0.0%
Covered Lines: 11091
Relevant Lines: 13097

💛 - Coveralls

@arvidn arvidn marked this pull request as ready for review January 31, 2024 14:49
@arvidn arvidn requested a review from haorldbchi January 31, 2024 18:05
Copy link

@harold-b harold-b left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

@haorldbchi haorldbchi left a comment

Choose a reason for hiding this comment

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

lgtm

@arvidn arvidn merged commit 7703088 into main Jan 31, 2024
59 checks passed
@arvidn arvidn deleted the optimize-db branch January 31, 2024 23:07
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.

3 participants