go-ethereum/eth
rjl493456442 b1f6dccfba
eth, les: rework chain tracer (#25143)
This PR simplifies the logic of chain tracer and also adds the unit tests.

The most important change has been made in this PR is the state management. Whenever a tracing state is acquired there is a corresponding release function be returned as well. It must be called once the state is used up, otherwise resource leaking can happen.

And also the logic of state management has been simplified a lot. Specifically, the state provider(eth backend, les backend) should ensure the state is available and referenced. State customers can use the state according to their own needs, or build other states based on the given state. But once the release function is called, there is no guarantee of the availability of the state.


Co-authored-by: Sina Mahmoodi <1591639+s1na@users.noreply.github.com>
Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2022-09-07 20:25:58 +02:00
..
catalyst all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
downloader all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
ethconfig all: move genesis initialization to blockchain (#25523) 2022-08-30 18:22:28 +02:00
fetcher all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
filters all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
gasprice all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
protocols all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
tracers eth, les: rework chain tracer (#25143) 2022-09-07 20:25:58 +02:00
api_backend.go eth, les: rework chain tracer (#25143) 2022-09-07 20:25:58 +02:00
api_test.go core, trie, eth, cmd: rework preimage store (#25287) 2022-07-27 20:37:04 +02:00
api.go eth, les: rework chain tracer (#25143) 2022-09-07 20:25:58 +02:00
backend.go all: move genesis initialization to blockchain (#25523) 2022-08-30 18:22:28 +02:00
bloombits.go eth: move eth.Config to a common package (#22205) 2021-02-05 13:51:15 +01:00
handler_eth_test.go all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
handler_eth.go all: update license headers and AUTHORS from git history (#24947) 2022-05-24 20:39:40 +02:00
handler_snap.go eth: check snap satelliteness, delegate drop to eth (#22235) 2021-02-02 10:44:36 +02:00
handler_test.go all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
handler.go cmd, core, eth, les, params: add merge-passed chain config (#24538) 2022-08-01 15:13:25 +03:00
peer.go all: more linters (#24783) 2022-06-13 16:24:45 +02:00
peerset.go all: fix some typos (#25551) 2022-08-19 09:00:21 +03:00
state_accessor.go eth, les: rework chain tracer (#25143) 2022-09-07 20:25:58 +02:00
sync_test.go eth: introduce eth67 protocol (#24093) 2022-06-15 12:56:47 +02:00
sync.go cmd, core, eth, les, params: add merge-passed chain config (#24538) 2022-08-01 15:13:25 +03:00