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

IF: P2P: Fix stuck in peer syncing state #27

Merged
merged 1 commit into from
Apr 15, 2024

Conversation

heifner
Copy link
Member

@heifner heifner commented Apr 12, 2024

Test failure: https://github.com/AntelopeIO/spring/actions/runs/8662797812/job/23755999003

The producing node (Node00) did not send to the validating node (Node02) because Node00 thought Node02 was still syncing from it. Node00 thought that Node02 was still syncing because when Node02 tried to send it the handshake after receiving blocks, it had not applied any of those blocks to its internal block chain state. Therefore, the handshake was not sent because nothing had changed.

Delay sending handshakes on becoming in_sync until controller state is caught up to head. This will make sure the handshake sent to other nodes reflects current synced up state instead of non synced up state. Also go from lib_catchup to head_catchup instead of jumping to in_sync so that the mechanism for determining to send handshakes does not miss the transition.

@heifner heifner requested review from greg7mdp and linh2931 April 12, 2024 18:56
@heifner heifner added the OCI Work exclusive to OCI team label Apr 12, 2024
@heifner heifner merged commit bfbdcca into savanna Apr 15, 2024
71 checks passed
@heifner heifner deleted the net-plugin-syncing-with-peer branch April 15, 2024 21:18
@ericpassmore
Copy link
Contributor

Note:start
group: IF
category: INTERNALS
summary: Fix stuck in peer syncing state. Delay sending in_sync until controller state is caught up to head, and judiciously apply sync states, and do not directly jump to in sync state.
Note:end

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.

4 participants