This repository has been archived by the owner on Oct 16, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Introducing roles! #36
Open
damirka
wants to merge
28
commits into
master
Choose a base branch
from
role-picking
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- my suggestion is to create single point of entry for all DBs - chaindata is replaced with core/db
- now core/db is the only point of access to data - backward compability is saved, so only few other changes were made - few bugs in stream pulling were fixed and now allow async writing - fewer console logs
- now both addProducer and addDelegate can refer to same address - removed lib/parser as it was only used in tests - removed console logs in tests
- improved lib/genesis to support multi-role records - now both addProducer and addDelegate can refer to same address - removed lib/parser as it was only used in tests - removed console logs in tests - mkdir -p after installation, removed state from initial genesis, fixed genesis block state - added adapter to generate state from genesis block
- role is an assignment for one round defined in start of it - both delegate and producer are just roles from now on - index.js is a key file which listens to all the events and plays both roles - no more /docs directory
damirka
added
enhancement
New feature or request
help wanted
Extra attention is needed
labels
Apr 22, 2019
- 2 new methods in services/waiter - constants are now able to define through env setting
- new lib/block-state util for parsing block state - in genesis and everywhere else 0x-prefixed addresses (yay!) - few changes around tx handling - we don't want errors - instead of certificates there's locked in genesis - we don't issue certificates from now on, we only lock coins
- use block-parser(block.state) for easier access - started implementing state support and usage in delegates role
- now delegates can know each other addresses from public keys
- finally consensus with N delegates works as expected - fixed sync bug so new nodes could not connect - role assignment works from start and as expected - observer now has function .observe() - runner prints log directory for each account address - fixed N delegates bug which led to only 1 response awaiting
- new event NEW_BLOCK_RECEIVED emitted when block is downloaded - reduced delegate wait time to 1 second instead of 5 - now role is defined on every block, not only first one
- now bp and delegate pull block only once - started refactoring of delegate block - block-producer code is more opaque and simple
Leveldown uses first char to define 'last record' so 9th block was always a last one. From now on we store 'latest' block.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
From now on there won't be any differentiation of 'clients'. I introduce you roles!
New roles:
Role is: