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

blockstore: Remove unnecessary function and threadpool #122

Merged
merged 3 commits into from
Mar 7, 2024

Conversation

steviez
Copy link

@steviez steviez commented Mar 6, 2024

Problem

This is somewhat of a follow on to solana-labs#34768. Namely, that PR removed a threadpool that was used to fetch entries. There is a similar thread pool that is used to fetch entries for the use-case of purging special columns. Regardless of the use-case, the sentiment that we shouldn't be using a threadpool to fetch the entries remains

Summary of Changes

  • Update Blockstore::purge_special_columns_exact() to use the public facing function
    • Use of allow_dead_slots == true retains previous functionality
  • Remove the now unused function
  • Removed the now unused threadpool

Note that the thread-pool was inside a lazy_static!, and would have only been accessed when Blockstore::clear_unconfirmed_slot() was called. That function gets called from ReplayStage when something is wrong (like the node forking off). So, any healthy node should not created this pool. Regardless, it is still good to cleanup

Work is part of #35

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.8%. Comparing base (b6f6fdb) to head (fb73572).
Report is 4 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##           master     #122     +/-   ##
=========================================
- Coverage    81.8%    81.8%   -0.1%     
=========================================
  Files         838      838             
  Lines      225947   225933     -14     
=========================================
- Hits       184923   184894     -29     
- Misses      41024    41039     +15     

Copy link

@AshwinSekar AshwinSekar left a comment

Choose a reason for hiding this comment

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

lgtm 🪓

@steviez steviez merged commit 26692e6 into anza-xyz:master Mar 7, 2024
35 checks passed
@steviez steviez deleted the rm_bstore_all_cpu_pool branch March 7, 2024 22:06
codebender828 pushed a commit to codebender828/agave that referenced this pull request Oct 3, 2024
In a previous change, we removed the threadpool used to fetch entries
in parallel in favor of combining all fetches into a single rocksdb
multi_get() call.

This change does the same thing, except for a threadpool that was used
to fetch entries when we needed them to purge the transaction status
and address signatures columns.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

3 participants