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

Inability to sync without connection to original validator #73

Closed
orogvany opened this issue Oct 26, 2018 · 1 comment
Closed

Inability to sync without connection to original validator #73

orogvany opened this issue Oct 26, 2018 · 1 comment
Labels
bug Something isn't working
Milestone

Comments

@orogvany
Copy link
Collaborator

in semuxBft,

 // Pick 2/3th active validator's height as sync target. The sync will not be
            // started if there are less than 2 active validators.
            OptionalLong target = activeValidators.stream()
                    .mapToLong(c -> c.getRemotePeer().getLatestBlockNumber() + 1)
                    .sorted()
                    .limit((int) Math.floor(activeValidators.size() * 2.0 / 3.0))
                    .max();

            if (target.isPresent() && target.getAsLong() > height) {
                sync(target.getAsLong());
            }

if a user is syncing from scratch and cannot connect directly to one of the main original seed nodes, they cannot sync. We should not need to get the height from one of main validators if we are not ourselves a validator.

@orogvany orogvany added the bug Something isn't working label Nov 4, 2018
@orogvany orogvany added this to the v1.5.0 milestone Nov 19, 2018
@orogvany
Copy link
Collaborator Author

orogvany commented Mar 3, 2019

fixed in #130

@orogvany orogvany closed this as completed Mar 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant