lighthouse/beacon_node/network/src
Paul Hauner 267d8babc8 Prepare proposer (#3043)
## Issue Addressed

Resolves #2936

## Proposed Changes

Adds functionality for calling [`validator/prepare_beacon_proposer`](https://ethereum.github.io/beacon-APIs/?urls.primaryName=dev#/Validator/prepareBeaconProposer) in advance.

There is a `BeaconChain::prepare_beacon_proposer` method which, which called, computes the proposer for the next slot. If that proposer has been registered via the `validator/prepare_beacon_proposer` API method, then the `beacon_chain.execution_layer` will be provided the `PayloadAttributes` for us in all future forkchoiceUpdated calls. An artificial forkchoiceUpdated call will be created 4s before each slot, when the head updates and when a validator updates their information.

Additionally, I added strict ordering for calls from the `BeaconChain` to the `ExecutionLayer`. I'm not certain the `ExecutionLayer` will always maintain this ordering, but it's a good start to have consistency from the `BeaconChain`. There are some deadlock opportunities introduced, they are documented in the code.

## Additional Info

- ~~Blocked on #2837~~

Co-authored-by: realbigsean <seananderson33@GMAIL.com>
2022-03-09 00:42:05 +00:00
..
beacon_processor Add log debounce to work processor (#3045) 2022-03-07 06:30:17 +00:00
router Custom RPC request management for sync (#3029) 2022-03-02 22:07:17 +00:00
service Filter non global ips from discovery (#3023) 2022-03-02 03:14:27 +00:00
subnet_service Improved peer management (#2993) 2022-02-18 02:36:43 +00:00
sync Prepare proposer (#3043) 2022-03-09 00:42:05 +00:00
error.rs Rename eth2_libp2p to lighthouse_network (#2702) 2021-10-19 00:30:39 +00:00
lib.rs Rename eth2_libp2p to lighthouse_network (#2702) 2021-10-19 00:30:39 +00:00
metrics.rs Cleanup small issues (#3027) 2022-03-01 01:49:22 +00:00
nat.rs rust 1.53.0 updates (#2411) 2021-06-18 05:58:01 +00:00
persisted_dht.rs Rename eth2_libp2p to lighthouse_network (#2702) 2021-10-19 00:30:39 +00:00
service.rs Custom RPC request management for sync (#3029) 2022-03-02 22:07:17 +00:00
status.rs Correctly update range status when outdated chains are removed (#2827) 2021-11-26 01:13:49 +00:00