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

Update Consensus not to dependent on validator module #7168

Closed
Tracked by #7011
shuse2 opened this issue May 13, 2022 · 0 comments · Fixed by #7169
Closed
Tracked by #7011

Update Consensus not to dependent on validator module #7168

shuse2 opened this issue May 13, 2022 · 0 comments · Fixed by #7169
Assignees
Milestone

Comments

@shuse2
Copy link
Member

shuse2 commented May 13, 2022

Description

  • Move BFT module into consensus
  • Update BFT module BFTParameters to store generator/BLS keys as below
{
	prevoteThreshold: bigint;
	precommitThreshold: bigint;
	certificateThreshold: bigint;
	validators: {
		address: Buffer,
		bftWeight: bigint,
		blsKey: Buffer,
		generatorKey: Buffer,
	}[];
	validatorsHash: Buffer;
}
  • BFTParameters now can have bft weight 0, and order by shuffled address
  • Add API getValidator(address: Buffer, height: number): Validator which returns Validator information for specified height. (it is used to get a generator key to check signature)
  • Update generator and consensus not to be dependent on validators module, but use bft module or consensus instead
  • Fix impliesMaximalPrevotes

Acceptance Criteria

  • Fix all unit tests
  • Check dpos example and ensure block execution / generation is working
@shuse2 shuse2 self-assigned this May 13, 2022
@shuse2 shuse2 added this to the Sprint 69 milestone May 16, 2022
shuse2 added a commit that referenced this issue May 19, 2022
Remove validator dependency from BFT, consensus and generator - Closes #7168
@shuse2 shuse2 closed this as completed May 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

1 participant