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

Update weight function to fix bias in nomination #4453

Merged
merged 1 commit into from
Sep 17, 2024

Conversation

bboston7
Copy link
Contributor

@bboston7 bboston7 commented Sep 4, 2024

Description

Part of #4387

This change adds an application-specific
HerderSCPDriver::getNodeWeight function that computes a validator's weight based on its quality as described in the config file. Much of this change is in the testing infrastructure, which stresses the new algorithm to demonstrate that it avoids biasing towards larger orgs.

The remaining work (to be done in follow up PRs) is:

  • Documentation explaining the new algorithm in src/herder/readme.md
  • A supercluster mission testing the upgrade from the old weight function to the new one.

Checklist

  • Reviewed the contributing document
  • Rebased on top of master (no merge commits)
  • Ran clang-format v8.0.0 (via make format or the Visual Studio extension)
  • Compiles
  • Ran all tests
  • If change impacts performance, include supporting evidence per the performance document

docs/stellar-core_example.cfg Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.cpp Outdated Show resolved Hide resolved
src/simulation/Simulation.h Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.h Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.cpp Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.cpp Outdated Show resolved Hide resolved
src/herder/test/HerderTests.cpp Show resolved Hide resolved
@bboston7
Copy link
Contributor Author

This is ready for another round of review!

Copy link
Contributor

@marta-lokhova marta-lokhova left a comment

Choose a reason for hiding this comment

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

one issue that needs addressing, otherwise this change looks good to me!

src/main/Config.h Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.cpp Outdated Show resolved Hide resolved
src/herder/HerderSCPDriver.cpp Outdated Show resolved Hide resolved
@marta-lokhova
Copy link
Contributor

Feel free to squash fixup commits and rebase also to prepare for merging

Part of stellar#4387

This change adds an application-specific
`HerderSCPDriver::getNodeWeight` function that computes a validator's
weight based on its quality as described in the config file. Much of
this change is in the testing infrastructure, which stresses the new
algorithm to demonstrate that it avoids biasing towards larger orgs.

The remaining work (to be done in follow up PRs) is:
* Documentation explaining the new algorithm in `src/herder/readme.md`
* A supercluster mission testing the upgrade from the old weight
  function to the new one.
@bboston7
Copy link
Contributor Author

Feel free to squash fixup commits and rebase also to prepare for merging

Done!

@marta-lokhova marta-lokhova added this pull request to the merge queue Sep 17, 2024
Merged via the queue into stellar:master with commit d2e025e Sep 17, 2024
14 checks passed
@bboston7 bboston7 deleted the scp-nomination branch September 17, 2024 19:36
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