Closed blukat29 closed 2 months ago
Seems like a good starting point. Here is a suggestion for the prototype structure. Maybe you already thought about this.
VerifyHeader()
in the ConsensusModule
is complex and strongly coupled with the governance handler, particularly regarding snapshots. Introducing a separate GovernanceModule
could provide an opportunity to refactor and reduce this complexity by decoupling these responsibilities.
@hyunsooda Exactly. That's what I am going to do next.
I imagine these modules can exist. The modules can refer each other via Init()
@hyunsooda Exactly! the module functions are indeed event handlers at various stages in block processing. A Kaia core functionality can be formulated as 'a set of customizations to the Ethereum block processing pipeline'. I just did not name them like OnBlockInsert. Tell me if you have any naming suggestions.
Proposed changes
CN
to expose its APIsConsensusModuleHost
; currently the only host is the Istanbul backend.ExecutionModuleHost
; where the only host is BlockChain.RewindableModuleHost
; where the only host is BlockChain.Types of changes
Please put an x in the boxes related to your change.
Checklist
Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.
I have read the CLA Document and I hereby sign the CLA
in first time contribute$ make test
)Related issues
Further comments
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...