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

Retry connection on height mismatch #2474

Merged
merged 2 commits into from
Aug 8, 2023

Commits on Aug 5, 2023

  1. subscriber: fix off-by-one in awaitHeight()

    Block count is literally a block counter, while block height is the height
    written in the block. For block zero the height is zero while we have one block
    in the chain and therefore the count is one. Persistent store operates with
    heights, therefore comparison should be adjusted by one.
    
    Signed-off-by: Roman Khimov <[email protected]>
    roman-khimov committed Aug 5, 2023
    Configuration menu
    Copy the full SHA
    08e9e29 View commit details
    Browse the repository at this point in the history

Commits on Aug 8, 2023

  1. ir: retry mainnet RPC connection if the node is outdated

    We can have a set of RPC nodes configured and we will switch them in runtime,
    but if the first node is outdated then the IR node will _always_ fail to
    start until RPC node catches up. We can have a better behaviour with node
    switching to other RPCs in this phase.
    
    Can't be done this easily for the sidechain since in most cases we have an
    internal node and it needs to go through the chain completely.
    
    Refs. #2426.
    
    Signed-off-by: Roman Khimov <[email protected]>
    roman-khimov committed Aug 8, 2023
    Configuration menu
    Copy the full SHA
    e3de08e View commit details
    Browse the repository at this point in the history