go-ethereum/eth
rjl493456442 e50aeac4d0
eth/traces: add state limit (#25812)
This PR introduces a new mechanism in chain tracer for preventing creating too many trace states.

The workflow of chain tracer can be divided into several parts:

- state creator generates trace state in a thread
- state tracer retrieves the trace state and applies the tracing on top in another thread
- state collector gathers all result from state tracer and stream to users

It's basically a producer-consumer model here, while if we imagine that the state producer generates states too fast, then it will lead to accumulate lots of unused states in memory. Even worse, in path-based state scheme it will only keep the latest 128 states in memory, and the newly generated state will invalidate the oldest one by marking it as stale.

The solution for fixing it is to limit the speed of state generation. If there are over 128 states un-consumed in memory, then the creation will be paused until the states are be consumed properly.
2022-10-06 10:48:04 +02:00
..
catalyst eth, miner: add timeout for building sealing block (#25407) 2022-10-03 14:10:00 +02:00
downloader all: fix docstrings 2022-10-04 09:18:02 +02:00
ethconfig eth, miner: add timeout for building sealing block (#25407) 2022-10-03 14:10:00 +02:00
fetcher all: cleanup tests (#25641) 2022-09-07 20:21:59 +02:00
filters all: fix docstrings 2022-10-04 09:18:02 +02:00
gasprice build: upgrade to go 1.19 (#25726) 2022-09-10 13:25:40 +02:00
protocols Merge pull request #25924 from holiman/comments_fix 2022-10-04 13:30:00 +03:00
tracers eth/traces: add state limit (#25812) 2022-10-06 10:48:04 +02:00
api_backend.go eth: return state error via GetEVM (#25876) 2022-09-27 13:16:54 +02:00
api_test.go core, trie, eth, cmd: rework preimage store (#25287) 2022-07-27 20:37:04 +02:00
api.go cmd, core, eth, les, light: track deleted nodes (#25757) 2022-09-27 10:01:02 +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 eth: fix a rare datarace on CHT challenge reply / shutdown 2022-09-20 14:14:24 +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 build: upgrade to go 1.19 (#25726) 2022-09-10 13:25:40 +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