Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Make account shrink configurable #17544 (backport #17778) #18013

Merged
merged 2 commits into from
Jun 17, 2021

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jun 16, 2021

This is an automatic backport of pull request #17778 done by Mergify.
Cherry-pick of 269d995 has failed:

On branch mergify/bp/v1.7/pr-17778
Your branch is up to date with 'origin/v1.7'.

You are currently cherry-picking commit 269d99583.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   accounts-bench/src/main.rs
	modified:   core/src/tvu.rs
	modified:   core/src/validator.rs
	modified:   ledger/src/blockstore_processor.rs
	modified:   local-cluster/src/validator_configs.rs
	modified:   runtime/benches/accounts.rs
	modified:   runtime/src/accounts.rs
	modified:   runtime/src/bank.rs
	modified:   runtime/src/serde_snapshot.rs
	modified:   runtime/src/serde_snapshot/tests.rs
	modified:   validator/src/main.rs

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   core/tests/snapshots.rs
	both modified:   ledger/src/bank_forks_utils.rs
	both modified:   runtime/src/accounts_db.rs
	both modified:   runtime/src/snapshot_utils.rs

To fix up this pull request, you can check it out locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.io/

@mergify mergify bot added conflicts automerge Merge this Pull Request automatically once CI passes labels Jun 16, 2021
@solana-grimes
Copy link
Contributor

😱 New commits were pushed while the automerge label was present.

@solana-grimes solana-grimes removed the automerge Merge this Pull Request automatically once CI passes label Jun 16, 2021
@jeffwashington jeffwashington force-pushed the mergify/bp/v1.7/pr-17778 branch from 3b9d1bb to c2722c2 Compare June 16, 2021 23:44
@mergify mergify bot added the automerge Merge this Pull Request automatically once CI passes label Jun 16, 2021
@jeffwashington
Copy link
Contributor

@lijunwangs I had to manually merge this. Please verify that I did it correctly.

Copy link
Contributor

@lijunwangs lijunwangs left a comment

Choose a reason for hiding this comment

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

looks good

@mergify mergify bot removed the automerge Merge this Pull Request automatically once CI passes label Jun 17, 2021
@mergify
Copy link
Contributor Author

mergify bot commented Jun 17, 2021

automerge label removed due to a CI failure

@mergify mergify bot added automerge Merge this Pull Request automatically once CI passes and removed automerge Merge this Pull Request automatically once CI passes labels Jun 17, 2021
@mergify
Copy link
Contributor Author

mergify bot commented Jun 17, 2021

automerge label removed due to a CI failure

lijunwangs and others added 2 commits June 17, 2021 10:42
1. Added both options for measuring space usage using total accounts usage and for individual store shrink ratio using an enum. Validator CLI options: --accounts-shrink-optimize-total-space and --accounts-shrink-ratio
2. Added code for selecting candidates based on total usage in a separate function select_candidates_by_total_usage
3. Added unit tests for the new functions added
4. The default implementations is kept at 0.8 shrink ratio with --accounts-shrink-optimize-total-space set to true

Fixes #17544

(cherry picked from commit 269d995)

# Conflicts:
#	core/tests/snapshots.rs
#	ledger/src/bank_forks_utils.rs
#	runtime/src/accounts_db.rs
#	runtime/src/snapshot_utils.rs
@jeffwashington jeffwashington force-pushed the mergify/bp/v1.7/pr-17778 branch from c2722c2 to 22bbe87 Compare June 17, 2021 15:42
@mergify mergify bot added the automerge Merge this Pull Request automatically once CI passes label Jun 17, 2021
@codecov
Copy link

codecov bot commented Jun 17, 2021

Codecov Report

Merging #18013 (22bbe87) into v1.7 (b472dac) will increase coverage by 0.0%.
The diff coverage is 95.8%.

@@           Coverage Diff            @@
##             v1.7   #18013    +/-   ##
========================================
  Coverage    82.5%    82.5%            
========================================
  Files         432      432            
  Lines      120366   120565   +199     
========================================
+ Hits        99304    99500   +196     
- Misses      21062    21065     +3     

@mergify mergify bot merged commit e9c234d into v1.7 Jun 17, 2021
@mergify mergify bot deleted the mergify/bp/v1.7/pr-17778 branch June 17, 2021 17:46
@brooksprumo brooksprumo mentioned this pull request Aug 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
automerge Merge this Pull Request automatically once CI passes conflicts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants