Konstantin
0753c94c2b
Epoch syncing - syncing only epoch blocks. ( #4070 )
...
* Epoch syncing - syncing only epoch blocks.
* Fix go test, added command to run.
* Block signature validation.
* Support getting block by height.
* Fix to compile.
* Http method.
* Generate fix.
* Install protoc-gen-go-grpc.
* Fix sync, additional timeouts, fix epoch.
* Chain behaviour options, optional state validation on blockchain initialization.
* Added limit to avoid abuse, small fixes.
* Fix duplicate code.
* Fix isInSyn.
* Fix method call.
* Removed additional block sending.
* Fix in sync.
* Code clean up.
* Fix beacon chain func.
* Return back Beaconchain.
* Fix sending only epoch blocks.
* Fix failed startup with validator.
* Increase recv message size.
* Remove peer.
* Add logs.
* Add logs.
* Fix msgf call.
* Epoch syncing - syncing only epoch blocks.
* Block signature validation.
* Fix sync, additional timeouts, fix epoch.
* Chain behaviour options, optional state validation on blockchain initialization.
* Support getting block by height.
* Http method.
* Fix duplicate code.
* Fix isInSyn.
* Added limit to avoid abuse, small fixes.
* Fix method call.
* Removed additional block sending.
* Fix in sync.
* Small fix.
* Code clean up.
* Fix beacon chain func.
* Return back Beaconchain.
* Fix sending only epoch blocks.
* Fix failed startup with validator.
* Increase recv message size.
* Remove peer.
* Add logs.
* Fix msgf call.
* Sending crosslinks from beacon to non-beacon chains.
* Receiving crosslinks.
* Broadcast.
* Fix comment.
* Crosslink signal.
* Crosslink hardbeat signal receiving.
* Sending crosslinks from beacon to non-beacon chains.
* Sending crosslinks from beacon to non-beacon chains.
* Broadcast.
* Fix comment.
* Crosslink signal.
* Crosslink signal.
* Add comment to run tests.
* Fix comments.
* Fix comments.
* Fix review comments.
* Updated with last crosslink heart beat signal.
* Merged crosslink signal.
* Clean up code.
* Add logs for cl debug.
* Stop iterate on receiving result.
* Add logs.
* Fix in sync check.
* Fix reconnect problems.
* Fix tests and reduce dependency.
* Updated with main.
* Fix review comments.
* Changed to compare epochs.
* Fix crosslinks usage.
* Fix initialization.
* Epoch chain implementation.
* Legacy sync by default.
* Revert "Legacy sync by default."
This reverts commit 5fa6ce002a
.
* Epoch sync for downloader.
* Build docker image while tests.
* Fix paths.
* Updated travis.
* Review improvements.
Co-authored-by: Konstantin <k.potapov@softpro.com>
2 years ago
Konstantin
06de7dcd6c
Fix race errors. ( #4184 )
...
* Fix data races.
* Fix block num.
* Pub key lock.
* Fixed race errors.
* Fix flag.
* Fix comments.
* Fix comments.
* Fix type.
* Fix race errors in tests.
Co-authored-by: Konstantin <k.potapov@softpro.com>
2 years ago
Rongjian Lan
d52a7c5b66
fix build
3 years ago
Rongjian Lan
11a4f87c3f
send 2/3 commit before block insertion in final commit; do not include txns in epoch block
3 years ago
Rongjian Lan
af30da7cff
keep proposing block
3 years ago
Rongjian Lan
d442ba9efc
Cache block processing results and reuse during block commitment to db ( #3905 )
...
* Cache block processing results and reuse during block commitment to db
* fix comments
3 years ago
Rongjian Lan
ef9fd043a2
Add vrf proposal and vrf epoch
4 years ago
Rongjian Lan
52ac53e6d1
limit crosslink in each block
4 years ago
Jacky Wang
f00c90e3e6
Graceful shutdown - All registered services are shutdown gracefully. ( #3533 )
...
1. Refactored service manager with cleaner interface.
2. Add prometheus to the service manager.
3. Graceful shutdown of the services (including consensus).
4. Some code refactor regarding consensus graceful shutdown.
Co-authored-by: Rongjian Lan <rongjian.lan@gmail.com>
4 years ago
Rongjian Lan
9381b95cdc
Remove special eth txn in block and block proposal logic. ( #3496 )
...
* Add ethereum transaction support
* fix fmt
* fix lint
* add new block body fork logic
* add back deleted code
* lower case block version const
* add eth txn into new version of block
* refactor back
* refactor more
* fix test code
* Fix build
* Fix build
* revert eth txn in block and block proposal
* fix build
* fix build
* fix build
4 years ago
Rongjian Lan
666033c3eb
Add InternalTransaction and CoreTransaction interface to abstract txns ( #3494 )
...
* Add ethereum transaction support
* fix fmt
* fix lint
* add new block body fork logic
* add back deleted code
* lower case block version const
* add eth txn into new version of block
* refactor back
* refactor more
* fix test code
* Fix build
* Fix build
4 years ago
Leo Chen
b38118fcbb
[node] graceful shutdown validators ( #3483 )
...
* [node] graceful shutdown validator and leader
when leader/validator is in commit phase, wait until it finishes the consensus
before shutdown the node.
This is useful for node upgrade to avoid unexpected blockchain state.
Signed-off-by: Leo Chen <leo@harmony.one>
* [node] stop block proposal service on leader
Signed-off-by: Leo Chen <leo@harmony.one>
* [node] warn on block proposal stopped
Signed-off-by: Leo Chen <leo@harmony.one>
Co-authored-by: Rongjian Lan <rongjian.lan@gmail.com>
4 years ago
Rongjian Lan
21b162cc67
Fix inconsistent block proposal and verification ( #3485 )
...
* Fix inconsistent block proposal and verification
* change log level and add comment
4 years ago
Rongjian Lan
8d878e575d
Fix viewID in block proposal
4 years ago
Rongjian Lan
8821807946
Fixes viewID and view change ID base
4 years ago
Rongjian Lan
b87f90e5dd
fix finality count for leader
4 years ago
Rongjian Lan
2aed5e16df
fix finality count for leader
4 years ago
Rongjian Lan
f91d781fe4
add Delayed sending
4 years ago
Rongjian Lan
0029ced6b2
Add constant for timeouts
4 years ago
Rongjian Lan
628174b379
fix block proposal
4 years ago
Rongjian Lan
41c5b42516
make block proposing timing aligned with pipelining
4 years ago
Rongjian Lan
0e95cb634b
fix sync race condition
4 years ago
Rongjian Lan
4aef0f4132
do not sent committed at 67%
4 years ago
Rongjian Lan
49d7985f14
some more logic cleanup
4 years ago
Rongjian Lan
ee3dd70676
merge
4 years ago
Rongjian Lan
611448a0a1
pipelining wireframe
4 years ago
Rongjian Lan
a666e14ef3
Add more tests
4 years ago
Rongjian Lan
af8fe283db
Add more comments and shorten timeout
4 years ago
Leo Chen
b76ac39d48
[viewchange] rename GetCurViewID to GetCurBlockViewID
...
Signed-off-by: Leo Chen <leo@harmony.one>
4 years ago
Leo Chen
a551c05ed8
[rpc] expose consensus internal data via rpc
...
This is used to debug consensus/viewchange state.
Signed-off-by: Leo Chen <leo@harmony.one>
4 years ago
Rongjian Lan
151286ce04
Fix travis
4 years ago
Rongjian Lan
6845775078
Make block proposal async and receiving last commit sig through channel
4 years ago
Leo Chen
42923336c9
[viewchange] encapsulate both viewID and viewChangeID
...
[viewchange] encapsulate view ID in the State struct
do NOT ues consensus.current directory to set/get viewID
use the following functions
consensus.SetCurViewID, consensus.SetViewChangingID
consensus.GetCurViewID, consensus.GetViewChangingID
Signed-off-by: Leo Chen <leo@harmony.one>
4 years ago
Rongjian Lan
19db99d3f7
Increase time buffer; add db cache; change log level
4 years ago
Rongjian Lan
9c0554ddc9
Use finer grained RWMutex for consensus logic ( #3239 )
...
* Use finer graned RWMutex for consensus logic
* Correct GOMAXPROCS to be the same as num CPUs
4 years ago
Rongjian Lan
8a08da67ca
Remove unused code and add benchmark for consensus msg check ( #3211 )
4 years ago
Rongjian Lan
67d77c3965
Refactor bls public key into a wrapper ( #3203 )
...
* Refactor bls public key into a wrapper
* Fix build
* Fix
4 years ago
Rongjian Lan
819500aa70
cherrypick log level change
5 years ago
Rongjian Lan
e85c1f3064
Fix log levels ( #3058 )
5 years ago
Rongjian Lan
ea2347fa5e
Cherrypick crosslink related fixes from t3 to master. ( #3045 )
...
* Optimize crosslink verification logic and add more cache (#3032 )
* make crosslink broadcast smarter and more efficient (#3036 )
* adjust catch up speed to be a sane number
* Fix crosslink broadcast condition (#3041 )
5 years ago
Rongjian Lan
eb4fcc93ab
Optimize crosslink verification logic and add more cache ( #3032 )
5 years ago
Rongjian Lan
b823126bfe
verify block before proposal ( #2968 )
...
* verify block before proposal
* only verify header after block proposal
5 years ago
Rongjian Lan
8fde77d88f
Revert merge normal and staking txns ( #2895 )
...
* Revert merge normal and staking txns
* fix lint
* fix build
5 years ago
Rongjian Lan
3808f5317b
Make commit sig committed along with the block ( #2875 )
...
* Make commit sig committed along with the block
* Fix type len check
5 years ago
Ganesha Upadhyaya
21327e697e
[core][node/worker] processing staking and normal transactions together ( #2869 )
...
* processing staking and normal transactions together
* bug fix and removing unwanted method
* made sense to rename and move the TransactionsByPriceAndNonce to pool type
* accounting for prestaking blocks, need to keep the previous order for processing txs
5 years ago
Ganesha Upadhyaya
4524e1b7ba
[node] move self address to node, make it updatable every epoch ( #2799 )
...
* [node] move self address to node, make it updatable every epoch
* golint issues
* making thread-safe, better naming, handling nil cases better
* golint
* correct locking, return on nil
5 years ago
Rongjian Lan
e484b556ae
optimize leader signature collection strategy; Clean up logs ( #2775 )
...
* Clean up logs
* remove log
* Refactor block period logic; wait for 100% sig before timeout
* logic fixes
* optimize now init
* always wait for 2s for grace period
5 years ago
Edgar Aroutiounian
9fa85b586b
[project] Remove dead Lottery app code, optimize node/... on what staticcheck showed ( #2688 )
5 years ago
Edgar Aroutiounian
2b578c0a58
[log] Data epoch & blocknum to subset of ds logs ( #2547 )
5 years ago
Edgar Aroutiounian
b54a17c2e4
[log] Add dedicated data science logger ( #2527 )
5 years ago