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

[3.1 -> main] net_plugin fix startup issue when peer does not have requested blocks #153

Merged
merged 4 commits into from
Sep 14, 2022

Conversation

heifner
Copy link
Member

@heifner heifner commented Sep 13, 2022

Test failure of #115 caused by peer not requesting blocks when no blocks where received from the sync source peer.

Two things contributed to this.

  1. The node was expecting blocks from a different source than the tracked sync_source because the sync_source was set to a different connection but no new request was sent. When the connection was closed that this node was expecting blocks from it did not request from a different connection because the sync_source indicated it was already syncing from a different connection. This caused it not to try a different connection on the close of the sync source connection.
  2. This should have timed out, but since no blocks were ever received it never sent a new handshake.

Changed to keep sync_source up to date with with the connection actually syncing from. This is done by only updating sync_source when a request to sync from a peer is made.
Also changed to always send a handshake on a block heart beat timeout since there is no harm in sending an extra handshake.

Merges #135 to main.
Resolves #115

@heifner heifner added the OCI Work exclusive to OCI team label Sep 13, 2022
@heifner heifner merged commit ad84c3a into main Sep 14, 2022
@heifner heifner deleted the GH-115-no-blocks-main branch September 14, 2022 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCI Work exclusive to OCI team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

block_log_retain_blocks_test failed in CICD
2 participants