1
0
Fork 0
forked from forks/go-ethereum
go-ethereum-modded-tocallarg/eth/downloader
rjl493456442 90d44e715d
core, eth/downloader: implement pruning mode sync (#31414)
This pull request introduces new sync logic for pruning mode. The downloader will now skip
insertion of block bodies and receipts before the configured history cutoff point.

Originally, in snap sync, the header chain and other components (bodies and receipts) were
inserted separately. However, in Proof-of-Stake, this separation is unnecessary since the
sync target is already verified by the CL.

To simplify the process, this pull request modifies `InsertReceiptChain` to insert headers
along with block bodies and receipts together. Besides, `InsertReceiptChain` doesn't have
the notion of reorg, as the common ancestor is always be found before the sync and extra
side chain is truncated at the beginning if they fall in the ancient store. The stale
canonical chain flags will always be rewritten by the new chain. Explicit reorg logic is
no longer required in `InsertReceiptChain`.
2025-04-03 15:16:35 +02:00
..
api.go eth/downloader, eth/tracer: fix typos in comments (#29707) 2024-05-29 14:43:07 +02:00
beacondevsync.go cmd, eth: switch the dev synctarget to hash from block (#28209) 2023-09-29 22:11:15 +03:00
beaconsync.go core, eth/downloader: implement pruning mode sync (#31414) 2025-04-03 15:16:35 +02:00
downloader.go core, eth/downloader: implement pruning mode sync (#31414) 2025-04-03 15:16:35 +02:00
downloader_test.go all: nuke total difficulty (#30744) 2025-01-28 18:55:41 +01:00
events.go cmd,eth: 16400 Add an option to stop geth once in sync. WIP for light mode (#17321) 2019-01-30 08:40:36 +01:00
fetchers.go eth/downloader: purge pre-merge sync code (#29281) 2024-04-30 15:46:53 +02:00
fetchers_concurrent.go eth/downloader: purge pre-merge sync code (#29281) 2024-04-30 15:46:53 +02:00
fetchers_concurrent_bodies.go all: implement flat deposit requests encoding (#30425) 2024-10-09 12:24:58 +02:00
fetchers_concurrent_receipts.go cmd/devp2p, eth: drop eth/66 (#28239) 2023-10-03 15:03:19 +03:00
metrics.go core, eth/downloader: implement pruning mode sync (#31414) 2025-04-03 15:16:35 +02:00
peer.go all: nuke total difficulty (#30744) 2025-01-28 18:55:41 +01:00
queue.go core, eth/downloader: implement pruning mode sync (#31414) 2025-04-03 15:16:35 +02:00
queue_test.go all: implement flat deposit requests encoding (#30425) 2024-10-09 12:24:58 +02:00
resultstore.go core, eth/downloader: implement pruning mode sync (#31414) 2025-04-03 15:16:35 +02:00
skeleton.go all: fix typos in docs and comments (#31548) 2025-04-02 13:52:40 -06:00
skeleton_test.go eth/downloader: fix flaky test (#29852) 2024-05-27 16:26:55 +02:00
statesync.go eth: request id dispatcher and direct req/reply APIs (#23576) 2021-11-26 13:26:03 +02:00
testchain_test.go all: remove forkchoicer and reorgNeeded (#29179) 2024-09-04 15:03:06 +02:00