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

prioritizes contact-infos in pull responses #16541

Merged
merged 1 commit into from
Apr 14, 2021

Conversation

behzadnouri
Copy link
Contributor

Problem

Expired crds values where the contact-info does not exist are wasted:
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/crds_gossip_pull.rs#L353-L378
and then are sent again over the next pull-request.

Also, the stake of the first response (which can be anything) is used to
weight all pull-responses to a node, while the rest of responses can
have different stake.
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/cluster_info.rs#L2231

Summary of Changes

  • Prioritize contact-infos in pull-responses.
  • Patch the stake weight bug.

Expired crds values where the contact-info does not exist are wasted:
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/crds_gossip_pull.rs#L353-L378
and then are sent again over the next pull-request.

Also, the stake of the first response (which can be anything) is used to
weight all pull-responses to a node, while the rest of responses can
have different stake.
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/cluster_info.rs#L2231
@behzadnouri behzadnouri requested a review from sakridge April 14, 2021 16:28
Copy link
Contributor

@sakridge sakridge left a comment

Choose a reason for hiding this comment

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

cool, lgtm

@behzadnouri behzadnouri linked an issue Apr 14, 2021 that may be closed by this pull request
@codecov
Copy link

codecov bot commented Apr 14, 2021

Codecov Report

Merging #16541 (8000f70) into master (74f5837) will decrease coverage by 0.0%.
The diff coverage is 52.6%.

@@            Coverage Diff            @@
##           master   #16541     +/-   ##
=========================================
- Coverage    80.0%    80.0%   -0.1%     
=========================================
  Files         413      413             
  Lines      112129   112127      -2     
=========================================
- Hits        89787    89766     -21     
- Misses      22342    22361     +19     

@behzadnouri behzadnouri merged commit f35a6a8 into solana-labs:master Apr 14, 2021
@behzadnouri behzadnouri deleted the prioritize-contact-info branch April 14, 2021 18:45
mergify bot pushed a commit that referenced this pull request Apr 14, 2021
Expired crds values where the contact-info does not exist are wasted:
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/crds_gossip_pull.rs#L353-L378
and then are sent again over the next pull-request.

Also, the stake of the first response (which can be anything) is used to
weight all pull-responses to a node, while the rest of responses can
have different stake.
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/cluster_info.rs#L2231

(cherry picked from commit f35a6a8)
mergify bot added a commit that referenced this pull request Apr 14, 2021
Expired crds values where the contact-info does not exist are wasted:
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/crds_gossip_pull.rs#L353-L378
and then are sent again over the next pull-request.

Also, the stake of the first response (which can be anything) is used to
weight all pull-responses to a node, while the rest of responses can
have different stake.
https://github.com/solana-labs/solana/blob/f804ce63c/core/src/cluster_info.rs#L2231

(cherry picked from commit f35a6a8)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
@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
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

100% Traffic increase after upgrade to v1.5.6
2 participants