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

Use correct index when iterating prioritized frontiers #2069

Merged
merged 5 commits into from
Jun 10, 2019

Conversation

wezrule
Copy link
Contributor

@wezrule wezrule commented Jun 8, 2019

#2053 changed the collection used for prioritizing frontiers to be a boost::multi_index container, but was iterating over the default (wrong) index afterwards. There's not really a way to test this as the active roots has no "insertion" order, I do however check that the roots does contain the expected frontier hashes though.

I've also modified the prioritize_frontiers_for_confirmation so that instead of stopping iterating when the container is full, it continues and replaces the frontier with the lowest amount of uncemented blocks with higher ones.

@wezrule wezrule added bug quality improvements This item indicates the need for or supplies changes that improve maintainability labels Jun 8, 2019
@wezrule wezrule added this to the V19.0 milestone Jun 8, 2019
@wezrule wezrule requested a review from SergiySW June 8, 2019 10:06
@wezrule wezrule self-assigned this Jun 8, 2019
@wezrule wezrule force-pushed the confirm_frontiers_iterate_order branch from 619ef5b to 6dbc011 Compare June 10, 2019 09:04
@wezrule wezrule merged commit 1669fd8 into nanocurrency:master Jun 10, 2019
@wezrule wezrule deleted the confirm_frontiers_iterate_order branch June 10, 2019 14:58
argakiig pushed a commit that referenced this pull request Jun 11, 2019
* Use correct index when iterating multi-index container

* Overwrite frontiers with low uncemented blocks with frontiers containing higher counts when max frontiers is reached

* Review comments

* Re-add removed stopped check in request loop

* Formatting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug quality improvements This item indicates the need for or supplies changes that improve maintainability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants