Commit Graph

1919 Commits

Author SHA1 Message Date
ledgerwatch
c5054334ac
Prune traces (#1993)
* Pruning of intermediate table

* Print pruning info

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-22 17:23:46 +01:00
Artem Vorotnikov
5655409616
Do not write old block changesets in pruning storage mode (#1964)
* Remove incremental staged sync

* Do not write old block changesets in pruning storage mode

* Remove pruning flag, put behaviour behind !StorageMode.History
2021-05-22 11:57:10 +01:00
ledgerwatch
729bfab988
Split DBSchema version depending on the database type (#1990)
* Split DBSchema version depending on the database type

* Fix test

* Fix test

* Fix lint

* Update migrations.go

* Update bucket.go

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-22 10:20:43 +01:00
ledgerwatch
7622e45713
Execution stage slow in download.v2 - drop all tx messages until after initial cycle (#1985)
* Rollback earlier

* Drop tx messages until after initial cycle

* Fix for stuck Ctrl-C

* Disable windows tests

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-21 20:07:23 +01:00
b00ris
f25a67b3b2
Fix final stage in replacement stages (#1983)
* fix

* gofmt

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-21 14:49:29 +01:00
Alex Sharov
0be3044b7e
rename (#1978)
* rename

* rename "make grpc"

* rename "abi bindings templates"

* rename "abi bindings templates"
2021-05-20 19:25:53 +01:00
Alex Sharov
215623da80
Windows support (#1944) 2021-05-20 23:46:12 +07:00
b00ris
d6c1cb5684
fix (#1976) 2021-05-20 15:17:57 +01:00
Alex Sharov
141fa4c3e2
set_snapshot_to_stageSync2 (#1975) 2021-05-20 14:29:27 +01:00
b00ris
c1bd26cc1f
Add snapshot stages to ReplacementStages (#1953)
* add snapshot layout stages

* fix lint
2021-05-20 13:17:47 +01:00
Alex Sharov
50934fa5d3
Move chain maiker to kv (#1972) 2021-05-20 18:49:33 +07:00
Alex Sharov
9d66aa0fe3
better support for mdbx in snapshots (#1971) 2021-05-20 18:12:07 +07:00
alex.sharov
ba29249f07 return error with details 2021-05-20 12:50:51 +07:00
ledgerwatch
14302bd271
Only unwind interhashes on root mismatch, not on cancellation (#1966)
* Only unwind interhashes on root mismatch, not on cancellation

* Fix

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-20 06:34:10 +01:00
Alex Sharov
57880b8817
fixes for dv2 cancelation (#1968)
* fixes

* fixes

* fixes

* fixes

* fixes
2021-05-20 06:33:55 +01:00
ledgerwatch
79084ede47
[download.v2] Make default (#1963)
* [download.v2] Make default

* Update server.go

* Fix for tmp files appearing in the current dir

* Fix test

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharov <AskAlexSharov@gmail.com>
2021-05-19 16:19:29 +01:00
Alex Sharov
781a67a4ee
Auto-Close db in tests by using t.Cleanup (#1956) 2021-05-19 10:47:28 +07:00
ledgerwatch
2b2153f387
[download.v2] No double p2p server (#1960)
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-19 00:49:38 +01:00
ledgerwatch
19b602a135
Stuck unwind fix, test, and recovery (#1959)
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-19 00:00:57 +01:00
ledgerwatch
0cc64e0f0f
Fix storageMode bug (no writing receipts/logs by default) (#1958)
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-18 15:27:39 +01:00
Alex Sharov
cceaf75b16
use t.TempDir() (#1955) 2021-05-18 19:13:16 +07:00
Alex Sharov
0c91bfbf3e
RPCDaemon: support Pending block (#1942)
* clean

* save

* pubsub

* pubsub

* pubsub

* pubsub

* pubsub

* pubsub

* save

* tx pub-sub

* tx pub-sub

* clean

* clean

* save

* save

* save

* save

* save

* Squashed 'interfaces/' content from commit c469f3ae0

git-subtree-dir: interfaces
git-subtree-split: c469f3ae073b60c8821b61fed2910191080ef835

* save

* save

* save

* save

* Squashed 'interfaces/' changes from c469f3ae0..958dfc669

958dfc669 save

git-subtree-dir: interfaces
git-subtree-split: 958dfc669f8daeefe686a13aa852fb95f1537886

* save

* save

* up some deps

* up some deps

* clean

* test

* test

* test

* test

* test

* test

* test

* test

* test

* test

* test

* test
2021-05-17 13:15:19 +01:00
ledgerwatch
86a94e8478
Avoid parsing transactions at Stage3 (#1940)
* RawBody

* Do not parse transaction during Stage3

* Reinstate delivery channel capacity, add comment

* Correct calculation of tx encoding for hashing

* fix logging of senders stage

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-16 20:01:14 +01:00
ledgerwatch
896be5fbe3
Trace Filter 7 (#1941)
* use roaring64

* Fix bitmap finalisation

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-16 20:01:04 +01:00
Artem Vorotnikov
66a8c23c37
Remove TrieDbState + other things (#1925)
* Remove old table from script

* Simplify ChangeSetWriter

* Move state tests to KV

* Simplify TrieCfg

* Port state tests away from TrieDbState

* Remove old MakePreState

* Upgrade t8ntool's MakePreState

* MakePreState2 -> MakePreState

* Remove TrieDbState
2021-05-16 06:21:29 +01:00
ledgerwatch
a92a449a97
Fix for call traces (#1939)
* Fix for call traces

* Bug to->from

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-15 23:44:29 +01:00
ledgerwatch
b47367eb8d
Defer tx pool start until the initial cycle end (#1937)
* Defer tx pool start until the initial cycle end

* Not print dropped messages

* Fix mock sentry test

* Fix test import cycle|

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-15 12:35:28 +01:00
ledgerwatch
7eefcbe6a6
fix RPC notification, add boilerplate for tests (#1936)
* fix RPC notification, add boilerplate for tests

* Fix test

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-14 22:16:16 +01:00
ledgerwatch
c4f746f54f
[download.v2] Recover from unwind panic (#1935)
* [download.v2] Recover from unwind panic

* Fix notifications and unwind

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-14 15:24:50 +01:00
Alex Sharov
2ff6ce7d92
move staged sync to tx (#1897) 2021-05-14 18:00:20 +07:00
ledgerwatch
61cba00081
Minor fixes (#1934)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-14 08:57:18 +01:00
b00ris
7948eafcc2
Property tests for kv snapshot (#1928)
* model tests for snapshot kv

* cursor test

* first failing test

* fix

* fix lint

* remove fmt
2021-05-13 09:40:32 +01:00
ledgerwatch
61df34b080
Fix headers subscriptions for download.v2 (#1923)
* Fix headers subscriptions for download.v2

* Use datadir to place nodes database for sentry

* Enable request chaining only after initial cycle

* Support for baikal and other in sentry

* Properly solve problem of stage1

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-12 22:37:43 +01:00
ledgerwatch
ddcf271ca5
Trace filter 6 (#1921)
* Improvements to stage1 in download.v2

* Stop timer earlier

* Stop timer earlier

* Print apends

* Fix traceCursor

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-12 17:35:46 +01:00
Alex Sharov
47d22773b9
[wip] dv2: Validate body (#1913)
* validate body

* validate body

* save

* save

* body deliveries messages handling into staged sync

* body deliveries messages handling into staged sync

* body deliveries messages handling into staged sync

* body deliveries messages handling into staged sync

* body deliveries messages handling into staged sync

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch

* penalize right after verifyUncles and stop, don't batch
2021-05-12 14:57:35 +01:00
ledgerwatch
319c167279
Improvements to stage1 in download.v2 (#1920)
* Improvements to stage1 in download.v2

* Stop timer earlier

* Stop timer earlier

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-12 12:40:23 +01:00
ledgerwatch
0aabf85c1d
Sentry fixes (for very frequent peer not found error) (#1918)
* Extra prints

* Remove printouts

* Printing back

* Fix the stuck stage 1

* Not allow peers to connect more than once

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-12 09:36:43 +01:00
ledgerwatch
bf0ea48823
Deadline-based permits in sentry (#1915)
* Not increase permit on announcements

* Init permits

* Deadlines

* Fix NPEs

* Fix NPE

* Fix findPeer

* Reduce max permits to 4

* 8 max permits, but 30 seconds timeout

* Back to 4

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-11 18:20:00 +01:00
ledgerwatch
0b7d185d1f
Trace filter 5 (and sentry improvement) (#1914)
* Append/AppendDup

* Print appends

* Remove printing

* Increase permit on announcements

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-11 13:58:43 +01:00
ledgerwatch
447f20d395
Baikal testnet configuration (#1910)
* Baikal testnet configuration

* Fixes

* Change AsMessage signature

* Fixes in t8ntool

* More updates

* Fix misspelling

* Skip eip1559 transition test

* More bootnodes

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-11 10:54:20 +01:00
Alex Sharov
0163329a5a
KV and RemoteKV: to reuse stateless cursors during transaction (#1909) 2021-05-11 15:23:17 +07:00
ledgerwatch
a99d22c313
Trace filter 4 + fixes for download.v2 (#1907)
* Introduce TraceCallSet bucket and fill it up

* Fix compile

* Reset TraceCallSet

* Add database.verbosity

* Warn about dropped messages

* Unwind for call traces

* Fixes for headers download

* Fix for the slow stage 3

* Remove wakeup channels

* Permit system for peer load balancing

* Reduce aggressiveness

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-10 16:07:22 +01:00
Artem Vorotnikov
80bbbf62c2
Misc fixes (#1908)
* Fix debug levels

* try this

* remove adapter

* fix

* fix bodies stage
2021-05-10 06:59:29 +01:00
ledgerwatch
128f446e7c
Download v2 fixes (#1903)
* [download.v2] Fix endianness of Difficulty in Status message

* Add comments

* Finish stage to use RwTx

* Print header age in stage 1

* Print new block messages

* TopSeenHeight to be updated from any header

* block in the future handling and skip the test

* Fix downloader test

* Fix test

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-09 08:22:08 +01:00
ledgerwatch
8907e95d4a
Trace filter 3 (#1904)
* Prevent the leak

* Default storage mode, fix leak again

* TopSeenHeight to be updated from any header

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-05-08 23:07:16 +01:00
ledgerwatch
5c512fbddb
Trace filter 2 (#1898)
* Fix error message about write protection

* Clean up of trace_filter

* Add CallTraces to Execution Stage

* Fix compile

* Say something

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-08 16:17:17 +01:00
b00ris
565a4250d6
Snapshot sync headers stage (#1836)
* save state

* snapshot update works

* save state

* snapshot migrator

* tx test

* save state

* migrations stages refactor

* refactor snapshot migrator

* compilation fixed

* integrate snapshot migrator

* goerli sync headers

* debug async snapshotter on goerly

* move verify headers, remove experiments, fix remove old snapshot

* save state

* refactor snapshotsync injection

* fix deadlock

* replace snapshot generation stage logic to migrate method

* change done for body snapshot

* clean

* clean&&change deleted value

* clean

* fix hash len

* fix hash len

* remove one of wrap methods, add remove snapshots on start

* add err check

* fix shadowing

* stages unwind order debug

* matryoshka experiments

* steam test

* fix build

* fix test

* fix lint

* fix test

* fix test datarace

* add get test

* return timeout

* fix mdbx overlap

* fix after merge

* change epoch size

* clean todo

* fix

* return testdata

* added return from sndownloader gorutine

* fix review comments

* Fix

* More info

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-08 09:45:40 +01:00
Artem Vorotnikov
09788dbc02
Pruning flag, incremental staged sync (#1899) 2021-05-08 00:07:49 +03:00
Alex Sharov
80ee37540e
penalize for abandoned anchor (#1896) 2021-05-07 06:17:40 +01:00
Alex Sharov
06cec6d535
Move exec to tx (#1887) 2021-05-07 09:06:44 +07:00
Alex Sharov
b2f424e2cd
Canonical fix in --download.v2 (#1886) 2021-05-07 09:06:00 +07:00
ledgerwatch
9fa21db40e
Qucker reaction to new block headers (#1894)
* Qucker reaction to new block headers

* Always print header lag

* Print verification time

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-06 19:40:12 +01:00
ledgerwatch
59e5502744
Initial work on RPC streaming (#1880)
* Initial work on RPC streaming

* Create the stream and pass it on

* trace_filter expressed as streamable (not finished)

* Reenable call trace index

* Add new line

* Remove storage mode override

* Tool for overriding storage mode

* Diagnostics

* Make trace_filter more streamy

* Streaming debug_traceTransaction and debug_traceCall

* Fix test

* Log error on stream flush

* Enable streaming for http

* Flush the stream too

* Make trace_filter flush too

* Stop streaming if client is not interested

* Try to quiet annoying test|

* Revert "Try to quiet annoying test|"

This reverts commit 42849257bfa52e90140aa535af34b957cd97a222.

* Debug log for test

* Proceed with handshake regardless of whether peer notification worked

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-06 18:37:38 +01:00
ledgerwatch
618acbffc1
Remove storageMode override (#1889)
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-06 08:39:10 +01:00
Alex Sharov
b1dc618b95
update stage progress before commit - to keep db always consistent (#1888) 2021-05-06 08:18:43 +01:00
Alex Sharov
e87d4932f7
Changeset writer move to tx (#1871) 2021-05-05 14:31:40 +07:00
Alex Sharov
c7eedf0091
Add kv to stage settings (because it doesn't change in runtime, tx will be passed as Stage func argument) (#1872)
* add kv to config

* move forward tx use

* move forward tx use

* gc stat

* gc stat

* changeset writer - move to tx

* clean

* clean

* clean

* clean

* clean
2021-05-04 13:36:03 +01:00
Artem Vorotnikov
2148885637
Simplify ChangeSet implementation and tests (#1878)
* Move storage changeset code into one file

* Simplify storage changeset tests

* simplify more

* more

* more

* more

* move account changeset into one file

* simplify account changeset test

* NewStorageChangesetPlain -> NewStorageChangeSet

* EncodeStoragePlain -> EncodeStorage

* StorageChangeSetPlain -> StorageChangeSet

* AccountChangeSetPlain -> AccountChangeSet

* more

* more

* more

* Simplify EncodeStorage

* more

* Simplify FromDBFormat

* more rename

* rename changeset buckets (constant names only)
2021-05-04 13:34:08 +01:00
ledgerwatch
793c13e20e
trace_filter and CallTrace Index (derivative of #1626) (#1867)
* Trace Index

* trace_filter

* hrtc -> hrt

* Fix CallTraces

* wip

* wip

* Fix for incorrect gas

* fix

* Fix Tracer

* Add block and uncle coinbases to trace index

* rewind coinbase

* Commit every 100k blocks after block 3m

* Simplify

* Safe unwinds

* Safe unwind 2

* Cleanup

* Simplification

* Remove intermediate JSON transform

* Reinstate optional CallIndex stage

* Create rpctest bench for trace_filter

* Fix trace_filter generator

* Restore unwind order

* Ignore the storage mode

* Ignore the storage mode

Co-authored-by: Artem Vorotnikov <artem@vorotnikov.me>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-04 07:23:54 +01:00
Alex Sharov
f3d2af1e33
Rpcdaemon: move tx pool to own grpc service, subscribe to pending txs (#1863) 2021-05-04 08:37:17 +07:00
Alex Sharov
f230ba1da4
Less use rawdb deprecated methods (#1861)
* less use deprecated methods

* less use deprecated methods

* auto Dp limit

* auto Dp limit

* add test
2021-05-03 21:01:01 +01:00
ledgerwatch
39d3314b99
[download.v2] Prevent deadlock by starting txPool early (#1860)
* Prevent deadlock by starting txPool early

* Reduce error levels in the logs

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-05-02 12:15:53 +01:00
Alex Sharov
08f6299257
broadcast new headers (#1847)
* broadcast new headers

* don't use eth type

* don't use eth type

* add seenAnnounces scet

* use lru
2021-05-01 21:03:51 +01:00
Alex Sharov
df8c5e3095
All stages - finish fast if current progress > target (#1773) 2021-05-01 17:08:59 +07:00
Alex Sharov
aacc457ea8
rawdb deprecated methods with Database interface (#1854) 2021-05-01 14:42:23 +07:00
ledgerwatch
34c1fdac21
Aleut fix for GASPRICE opcode (#1852)
* Aleut fix for GASPRICE opcode

* Fix for tip+basefee > feecap

* Unbork

* Fix tests

* Remove setHead test

* Test fix

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-04-30 19:20:18 +01:00
Alex Sharov
249b3098cb
add --sentry.api.addr flag (#1850)
* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr

* add --sentry.api.addr
2021-04-30 16:09:03 +01:00
Alex Sharov
c313238e4a
less blockchain objects in tests (#1844) 2021-04-29 16:14:19 +01:00
ledgerwatch
75ca6b8c76
Initial work on integration tests (#1797)
* Initial work on integration tests

* Delete subtree

* Squashed 'interfaces/' content from commit 41a082ba4

git-subtree-dir: interfaces
git-subtree-split: 41a082ba4bde38647325eb0416cb1da1b4ca2b12

* Add consensus interfaces

* More stuff

* comments

* Fix compile

* Squashed 'interfaces/' changes from 41a082ba4..1b13a42a7

1b13a42a7 Add chainspec to consensus interface

git-subtree-dir: interfaces
git-subtree-split: 1b13a42a7803f5464722867a71065c27a7ebe8c3

* Squashed 'interfaces/' changes from 1b13a42a7..93a072c4c

93a072c4c Add missing import

git-subtree-dir: interfaces
git-subtree-split: 93a072c4c099d169322a3a53b95e40203276820b

* New consensus interfaces

* More on clique

* Fix tests

* Squashed 'interfaces/' changes from 93a072c4c..62f4ec4b2

62f4ec4b2 Add test service for consensus engine

git-subtree-dir: interfaces
git-subtree-split: 62f4ec4b263107635ffa3aabd5d634af22e813c6

* Squashed 'interfaces/' changes from 62f4ec4b2..061a63543

061a63543 Fix

git-subtree-dir: interfaces
git-subtree-split: 061a63543babdeb51ab7e3a96dec56b2485d4389

* Configuring clique engine with toml specs - start

* More toml parsing

* Constructed rinkeby genesis

* Simplify VerifyHeaders functions

* Fix lint

* Remove concurrent verification tests

* Fix lint

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-29 16:14:10 +01:00
ledgerwatch
6cbfff354d
[download-v2] Use Clique instead of EtHash for clique networks (#1832)
* Use Clique instead of EtHash for clique networks

* Start tx fetcher, enable GetPooledTx in sentry

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-28 14:44:29 +01:00
ledgerwatch
03beaf4df7
Connect txPool to download.v2 to resolve 1 reason for "frozen download" (#1830)
* Pass txPool into new staged sync

* Remove poolStart function

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-27 16:37:03 +01:00
Alex Sharov
9cc4a0a97c
rebort db metrics - not guilty (#1828) 2021-04-27 15:32:41 +07:00
Alex Sharov
9d82456f17
remove chain indexer and core.setHead func (#1826) 2021-04-27 14:48:59 +07:00
ledgerwatch
04bbd07749
Move sentry message to log.Debug for download.v2 mode (#1817)
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-26 15:40:46 +01:00
Alex Sharov
01ae962459
Clean tmp on start (#1808)
* fininish to remove chain context

* clean

* move migrations folder from
<datadir>/etl-tmp/migrations
to
<datadir>/migrations
2021-04-26 13:51:01 +01:00
emhane
4823039a3d
Update README.md (#1815)
Correct typo.
2021-04-26 11:21:51 +01:00
Alex Sharov
4e80d6eeed
Pending txs subscription (#1810) 2021-04-26 16:53:38 +07:00
Alex Sharov
c40c3b7a7a
exec unwind etl (#1806) 2021-04-26 10:41:31 +01:00
Alex Sharov
472e161e33
fininish to remove chain context (#1807) 2021-04-26 14:23:21 +07:00
Alex Sharov
eee9438625
deprecate PlainDbState in favor of PlainKvState (#1805) 2021-04-26 12:37:48 +07:00
Alex Sharov
3af0b9b591
add hashstate, trie, history, logIndex stages (#1799)
* add hashstate and trie stages

* add history stages

* add history stages

* add history stages

* add logindex stage

* add logindex stage

* add other stages
2021-04-25 09:29:39 +01:00
ledgerwatch
88e8828bbd
Not rewind chain on hard forks (#1798)
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-04-25 07:14:10 +01:00
Alex Sharov
d959986466
Connect TxFetcher to Sentry, Add --download.v2 option to TG (#1796) 2021-04-25 11:20:50 +07:00
ledgerwatch
e3f3dd3c9b
Integration tests 1 (#1793)
* Initial commit

* Add sentry gRPC interface

* p2psentry directory

* Update README.md

* Update README.md

* Update README.md

* Add go package

* Correct syntax

* add external downloader interface (#2)

* Add txpool (#3)

* Add private API (#4)

* Invert control.proto, add PeerMinBlock, Separare incoming Tx message into a separate stream (#5)

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>

* Separate upload messages into its own stream (#6)

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>

* Only send changed accounts to listeners (#7)

* Txpool interface doc (#9)

* Add architecture diagram source and picture (#10)

* Typed hashes (#11)

* Typed hashes

* Fix PeerId

* 64-bit tx nonce

* Add proper golang packages, max_block into p2p sentry Status (#12)

* Add proper golang packages, max_block into p2p sentry Status

* Change EtherReply to address

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>

* Add Rust infrastructure (#13)

* DB stats methods removed by https://github.com/ledgerwatch/turbo-geth/pull/1665

* more p2p methods (#15)

* add mining methods (#16)

* First draft of Consensus gRPC interface (#14)

* Update Rust build

* Fix interfaces in architecture diagram (#17)

* Fix KV interface provider

* Fix Consensus interface provider

* drop java attributes (#18)

* tx pool remove unused import (#19)

* ethbackend: add protocol version and client version (#20)

* Add missing ethbackend I/F (#21)

* Add interface versioning mechanism (#23)

Add versioning in KV interface

Co-authored-by: Artem Vorotnikov <artem@vorotnikov.me>

* spec of tx pool method (#24)

* spec of tx pool method (#25)

* Update version.proto

* Refactor interface versioning

* Refactor interface versioning

* Testing interface

* Remove tree

* Fix

* Build testing protos

* Fix

* Fix

* Update to the newer interfaces

* Add ProtocolVersion and ClientVersion stubs

* Hook up ProtocolVersion and ClientVersion

* Remove service

* Add compatibility checks for RPC daemon

* Fix typos

* Properly update DB schema version

* Fix test

* Add test for KV compatibility|

* Info messages about compability for RPC daemon

* DB schema version to be one key

* Update release intructions

Co-authored-by: Artem Vorotnikov <artem@vorotnikov.me>
Co-authored-by: b00ris <b00ris@mail.ru>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: lightclient <14004106+lightclient@users.noreply.github.com>
Co-authored-by: canepat <16927169+canepat@users.noreply.github.com>
Co-authored-by: Alex Sharov <AskAlexSharov@gmail.com>
Co-authored-by: canepat <tullio.canepa@gmail.com>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-04-24 16:46:29 +01:00
Alex Sharov
ac7ece4a4d
Revert txpool grpc (#1794) 2021-04-24 10:48:06 +07:00
Evgeny Danilenko
984daa4d7a
Clique snapshot timer fixed (#1789)
* fix clique snapshot storage by timer

* after merge

* remove debug

* remove debug

* debug logging

* correct t.Fatal
2021-04-23 20:47:06 +03:00
Alex Sharov
d7d790725b
Add stage exec to downloader (#1788) 2021-04-23 17:27:07 +07:00
Alex Sharov
10c41491fa
Use Config struct for headers/body/senders stages. Add StageSenders to new downloader. (#1787)
* config for headers/body/senders

* clean
2021-04-23 16:16:45 +07:00
ledgerwatch
12cde41772
Aleut support (Eip1559) (#1704)
* Where I am at

* Refactoring of transaction types

* More refactoring

* Use Homested signer in rpc daemon

* Unified signer

* Continue unified signer

* A bit more

* Fixes and down the rabbit hole...

* More tx pool fixes

* More refactoring fixes

* More fixes'

* more fixes

* More fixes

* More compile fixes

* More RLP hand-writing

* Finish RLP encoding/decoding of transactions

* Fixes to header encoding, start on protocol packets

* Transaction decoding

* Use DecodeTransaction function

* Decoding BlockBodyPacket

* Encode and decode for pool txs

* Start fixing tests

* Introduce SigningHash

* Fixes to SignHash

* RLP encoding fixes

* Fixes for encoding/decoding

* More test fixes

* Fix more tests

* More test fixes

* More test fixes

* Fix core tests

* More fixes for signer

* Fix for tx

* Fixes to string encoding/size

* Fix eip2930 test

* Fix rest of ./tests

* More fixes

* Fix compilation

* More test fixes

* More test fixes

* Test fixes

* More fixes

* Reuse EncodingSize in EncodeRLP for accessList

* Rearrange things in dynamic fee tx

* Add MarshalBinary

* More fixes

* Make V,R,S non-pointers

* More NPE fixes

* More fixes

* Receipt fixes

* Fix core/types

* Fix ./eth

* More compile fixes for tests

* More test fixes

* More test fixes

* Try to see lint errors better

* Try to see lint errors better

* Fix lint

* Debugging eip1559 test

* Fix TestEIP1559Transition test

* Fix NewBlockPacket encoding/decoding

* Fix calculation of TxHash

* Fix perf problem with senders

* Update aleut config values

* Try adding static peers

* Add staticpeers to defaul flags

* Change aleut networkID

* Fix test

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-22 18:11:37 +01:00
ledgerwatch
80a3edae2f
Fixes to the sentry/downloader (#1767)
* Complete eth/66 migration, temporary disable broadcast

* Update header stage progress correctly

* Fix restarting

* Not pass blockPropagator to headers stage

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2021-04-21 23:24:01 +01:00
Alex Sharov
4b803bfa6a
Notify RPCDaemon after sync cycle commit (#1772) 2021-04-21 17:58:23 +07:00
Artem Vorotnikov
9a3e47a498
Remove StateCache where unused (#1770) 2021-04-21 16:14:23 +07:00
Alex Sharov
bbe9af3e25
Stages as const (#1774) 2021-04-21 15:02:21 +07:00
Alex Sharov
41fa29d421
Mining fixes (#1771) 2021-04-21 12:01:25 +07:00
Artem Vorotnikov
c967655c1d
More cleanups (#1765) 2021-04-21 08:48:37 +07:00
alex.sharov
e25b57511d fix nil pointer in peer 2021-04-20 23:34:54 +07:00
alex.sharov
b08532b278 fix nil pointer in peer 2021-04-20 23:24:09 +07:00
Alex Sharov
bf1c219531
Move txPool.Get method behind direct-grpc (#1760) 2021-04-20 21:41:46 +07:00
Alex Sharov
22980c11a1
create make_protocols_method similar to eth.MakeProtocols (#1754) 2021-04-20 12:36:25 +07:00
Alex Sharov
bf6f042a5d
Start mining on new tx (#1740) 2021-04-20 09:12:08 +07:00
Evgeny Danilenko
17c07c50a5
Move clique buckets to separate DB (#1703)
* debug

* debug

* it works

* rename clique bucket

* remove genesis special case

* copy snapshot

* remove debug

* migration

* debug

* regenerate snapshots

* simplify

* regeneration

* after merge

* tests

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-04-19 22:58:05 +01:00
Alex Sharov
e44b5eb84e
less blockchain object use step 5 (#1751) 2021-04-19 15:36:50 +07:00
Alex Sharov
5019610cfb
remove database field from Ethereum object (#1750) 2021-04-19 14:56:44 +07:00
Alex Sharov
368f37a02f
Simplify blockchain obj, step 5 (#1739) 2021-04-18 12:27:07 +07:00
Alex Sharov
b6a58b8263
Eth 66 sentry (#1721)
* eth66

* eth66

* test v0

* save

* sentry handshake test

* sentry handshake test

* sentry handshake test

* clean

* clean

* clean

* clean

* clean

* clean
2021-04-16 14:05:35 +01:00
Alex Sharov
9273090761
Move TxPool stage to rwtx (#1734) 2021-04-16 13:30:58 +07:00
Alex Sharov
a6541b5402
[merge after release] remove trie cache cli flags and logic (#1725) 2021-04-15 17:06:38 +07:00
Alex Sharov
5703059f29
[merge after release] Move history stage to rwtx (#1727) 2021-04-15 17:06:30 +07:00
Alex Sharov
f4a0839ff7
[merge after release] move ih stage to rwtx (#1726) 2021-04-15 17:05:55 +07:00
Alex Sharov
4aa90a347c
remove blockchain object from handler test (#1723) 2021-04-15 12:02:16 +07:00
Alex Sharov
fd22c39611
Share logic between handlers.go and new downloader (#1716) 2021-04-14 14:26:32 +07:00
Alex Sharov
2050127f01
Remove eth64 (#1715) 2021-04-13 21:48:36 +07:00
Alex Sharov
e473e0b4d9
lint fixes (#1717) 2021-04-13 21:48:20 +07:00
Artem Vorotnikov
eb64d4738d
More KVGetter (#1697) 2021-04-08 23:16:33 +07:00
Alex Sharov
c3776f7539
[merge after release] handle case when no senders in db yet (#1695) 2021-04-08 22:03:22 +07:00
Alex Sharov
9cff853d1e
tx less wrappers (#1694) 2021-04-08 18:03:45 +07:00
Alex Sharov
55904950c2
enr discovery (#1690) 2021-04-08 07:37:33 +01:00
Alex Sharov
9527671e5e
Remove blockchain object step3 (#1684) 2021-04-07 12:38:43 +07:00
Alex Sharov
a913ae8847
Remove chainContext object (#1683) 2021-04-06 16:52:53 +07:00
Alex Sharov
7452cc7f7f
Broadcast new blocks - basic functions (#1675) 2021-04-06 12:54:50 +07:00
Alex Sharov
cc539ce266
Remove blockchain.InsertChain method (#1681) 2021-04-06 12:06:07 +07:00
Artem Vorotnikov
b71c6323a0
KVGetter, replace old geth interfaces with it (#1676) 2021-04-05 20:04:58 +07:00
Alex Sharov
07e96fc055
clean (#1677) 2021-04-05 14:48:16 +07:00
Alex Sharov
eb1897cb7d
remove blockchain.InsertChain call from downloader (#1674) 2021-04-05 13:00:54 +07:00
Artem Vorotnikov
dbc0db0856
Nuke old miner and mux (#1666) 2021-04-03 13:09:31 +07:00
Alex Sharov
ad342b27ab
Mdb no db size log (#1665) 2021-04-03 10:30:28 +07:00
Alex Sharov
9a9c5b298a
bitmapdb to use rwtx (#1661) 2021-04-03 08:52:45 +07:00
Artem Vorotnikov
1bedfc1965
Nuke remnants of non-staged-sync modes (#1664) 2021-04-03 08:48:57 +07:00
Alex Sharov
fbfc43da7e
etl to use rwtx (#1660) 2021-04-02 18:22:25 +07:00
Alex Sharov
ef77eb3053
tx.RwCursor() to return err (first step of removing lazy cursors) (#1656) 2021-04-02 13:36:49 +07:00
Alex Sharov
abe5bd879c
Remove old loader, step 3 (remove some tds and blockchain objects in tests) (#1647) 2021-04-01 12:36:22 +07:00
Alex Sharov
f6effa5b48
Remove old loader, part 2 (#1642) 2021-03-31 22:30:09 +07:00
Alex Sharov
dcd081412e
remove unused metrics (#1643) 2021-03-31 16:24:39 +07:00
Alex Sharov
b4a2d823c4
old loader remove v1 (#1641) 2021-03-31 14:43:12 +07:00
Artem Vorotnikov
d4c10c9a47
Port rpcdaemon to KV interface (#1627) 2021-03-30 12:53:54 +03:00
Alex Sharov
4a176e4409
Mining docs (#1628) 2021-03-30 16:18:57 +07:00
Alex Sharov
86ccfd0338
RPC: Pending transactions/blocks/logs (#1625) 2021-03-30 14:09:00 +07:00
Artem Vorotnikov
9b8cdc0f22
Fix lints and remove more unused code (#1621) 2021-03-29 10:58:45 +07:00
Alex Sharov
0685250095
metrics for header/body/exec stages (#1618) 2021-03-28 21:40:42 +07:00
Alex Sharov
8ccc6b2664
Mining: remove local pow mining (from ethash), --miner.notify is required now, cycle is non-blocking now (#1617) 2021-03-28 21:40:27 +07:00
Alex Sharov
5f6513de31
Remove blockchain object from some tests (#1612) 2021-03-28 20:41:47 +07:00
Alex Sharov
416a69ecb3
Genesis.toBlock remove db from arguments (#1611) 2021-03-28 16:27:06 +07:00
ledgerwatch
270f866b06
rpctest commands to support block ranges, integration tool to allow tx tracing into files (#1616)
* block range options for rpctest

* convert bench8 to fastjson

* Add txtrace to integration tool

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-03-27 21:43:38 +00:00
Artem Vorotnikov
afe551ba1c
Remove puppeth & account management (#1610) 2021-03-26 21:05:42 +03:00
Alex Sharov
2bb70fca9f
Genesis: calculate root by common components (#1608) 2021-03-26 17:05:35 +07:00
Artem Vorotnikov
e67be2b1be
Remove unused code (#1604)
* Remove graphql, legacy options

* Remove CODEOWNERS

* Remove EWASM and custom EVM interpreter
2021-03-26 09:08:01 +07:00
Alex Sharov
2e1f880046
Mining test: set correct header.Timestamp and header.GasLimit (#1603) 2021-03-25 21:26:12 +07:00
Alex Sharov
bdd04f6674
Mining: to use correct ibs snapshot (#1601) 2021-03-25 14:57:20 +07:00
Alex Sharov
8e385d9648
Mining: use noop writer when applyTx, pending logs subscription (#1600) 2021-03-25 13:42:45 +07:00
ledgerwatch
ea15c4a4fd
Fixes to new downloader (#1599)
* Fix for prefetched bodies

* Do not reset headers stage to 0

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2021-03-24 22:37:29 +00:00