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

adds fallback logic if retransmit multicast fails (backport #17714) #18498

Merged
merged 2 commits into from
Jul 7, 2021

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jul 7, 2021

This is an automatic backport of pull request #17714 done by Mergify.
Cherry-pick of be957f2 has failed:

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

You are currently cherry-picking commit be957f25c.
  (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:   core/src/retransmit_stage.rs
	modified:   core/tests/gossip.rs

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   core/src/cluster_info.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/

In retransmit-stage, based on the packet.meta.seed and resulting
children/neighbors, each packet is sent to a different set of peers:
https://github.com/solana-labs/solana/blob/708bbcb00/core/src/retransmit_stage.rs#L421-L457

However, current code errors out as soon as a multicast call fails,
which will skip all the remaining packets:
https://github.com/solana-labs/solana/blob/708bbcb00/core/src/retransmit_stage.rs#L467-L470

This can exacerbate packets loss in turbine.

This commit:
  * keeps iterating over retransmit packets for loop even if some
    intermediate sends fail.
  * adds a fallback to UdpSocket::send_to if multicast fails.

Recent discord chat:
https://discord.com/channels/428295358100013066/689412830075551748/849530845052403733

(cherry picked from commit be957f2)

# Conflicts:
#	core/src/cluster_info.rs
@mergify mergify bot added conflicts automerge Merge this Pull Request automatically once CI passes and removed automerge Merge this Pull Request automatically once CI passes labels Jul 7, 2021
@mergify
Copy link
Contributor Author

mergify bot commented Jul 7, 2021

automerge label removed due to a CI failure

@mergify mergify bot added the automerge Merge this Pull Request automatically once CI passes label Jul 7, 2021
@codecov
Copy link

codecov bot commented Jul 7, 2021

Codecov Report

Merging #18498 (998099e) into v1.6 (6bc9149) will increase coverage by 0.0%.
The diff coverage is 55.0%.

@@           Coverage Diff           @@
##             v1.6   #18498   +/-   ##
=======================================
  Coverage    82.3%    82.3%           
=======================================
  Files         423      423           
  Lines      117704   117711    +7     
=======================================
+ Hits        96892    96901    +9     
+ Misses      20812    20810    -2     

@mergify mergify bot merged commit 1be989c into v1.6 Jul 7, 2021
@mergify mergify bot deleted the mergify/bp/v1.6/pr-17714 branch July 7, 2021 22:36
@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.

1 participant