prysm-pulse/beacon-chain/blockchain
David adabd1fa4f
service.head race condition fix (#10741)
* added various read mutex locks for service.head

* added RLocks around all calls to s.headRoot()

* added RLocks around all calls to s.headBlock()

* reduce lock surface-> Stop(),handleEpochBoundary()

* refactor Stop() to +performance, -lock_surface

* Apply suggestions from code review

Co-authored-by: terencechain <terence@prysmaticlabs.com>

* fixed indentation

Co-authored-by: terencechain <terence@prysmaticlabs.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
2022-05-27 14:24:43 +00:00
..
store Chain info: Return err if checkpoint is nil (#10729) 2022-05-20 18:41:33 +00:00
testing Chain info: Return err if checkpoint is nil (#10729) 2022-05-20 18:41:33 +00:00
blockchain_test.go Replace ioutil with io and os (#10541) 2022-04-18 20:42:07 +00:00
BUILD.bazel Move ExecutionPayload Utils to Consensus Types Subpackage (#10732) 2022-05-23 21:57:32 +00:00
chain_info_norace_test.go Move Consensus Type Wrappers Into Consensus Types Package (#10598) 2022-05-02 15:43:40 +00:00
chain_info_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
chain_info.go Chain info: Return err if checkpoint is nil (#10729) 2022-05-20 18:41:33 +00:00
checktags_test.go ran gofmt @ v1.17, these are the resulting changes (#10362) 2022-03-14 15:58:13 -05:00
error_test.go More selective on marking block as bad (#10681) 2022-05-20 17:05:39 +00:00
error.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
execution_engine_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
execution_engine.go Consolidate blockchain errors (#10736) 2022-05-22 17:48:54 +00:00
head_sync_committee_info_test.go Remove Eth2-Types Dependency in Prysm (#10578) 2022-04-29 10:32:11 -04:00
head_sync_committee_info.go Remove Eth2-Types Dependency in Prysm (#10578) 2022-04-29 10:32:11 -04:00
head_test.go Cache and use justified and finalized payload block hash (#10657) 2022-05-10 21:20:28 +00:00
head.go service.head race condition fix (#10741) 2022-05-27 14:24:43 +00:00
init_sync_process_block_test.go Move Consensus Type Wrappers Into Consensus Types Package (#10598) 2022-05-02 15:43:40 +00:00
init_sync_process_block.go Consolidate blockchain errors (#10736) 2022-05-22 17:48:54 +00:00
init_test.go Config registry (#10683) 2022-05-20 07:16:53 +00:00
log_test.go Use Single Beacon Block Wrapper Function Across Prysm (#10608) 2022-05-04 11:55:35 +08:00
log.go Change synced new block log (#10724) 2022-05-22 16:57:48 +00:00
metrics_test.go Move Shared/Testutil into Testing (#9659) 2021-09-23 18:53:46 +00:00
metrics.go Rename Block Package in Consensus-Types to Interfaces (#10605) 2022-05-02 14:32:37 -04:00
mock_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
new_slot_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
new_slot.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
options.go Payload ID caching (#10481) 2022-04-06 16:36:52 -07:00
pow_block_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
pow_block.go Move BeaconBlockNil Checker Function to Consensus-Types/Wrapper Package (#10731) 2022-05-20 23:29:16 +00:00
process_attestation_helpers.go Move BeaconBlockNil Checker Function to Consensus-Types/Wrapper Package (#10731) 2022-05-20 23:29:16 +00:00
process_attestation_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
process_attestation.go Implement fork choice spec tests (#10159) 2022-01-31 19:03:48 +00:00
process_block_helpers.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
process_block_test.go Update proposer boost score and spec tests (#10665) 2022-05-23 23:08:24 +00:00
process_block.go service.head race condition fix (#10741) 2022-05-27 14:24:43 +00:00
receive_attestation_test.go handle failure to update head (#10651) 2022-05-12 16:36:46 +00:00
receive_attestation.go service.head race condition fix (#10741) 2022-05-27 14:24:43 +00:00
receive_block_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
receive_block.go Update proposer boost score and spec tests (#10665) 2022-05-23 23:08:24 +00:00
service_norace_test.go Move Consensus Type Wrappers Into Consensus Types Package (#10598) 2022-05-02 15:43:40 +00:00
service_test.go Do not update forkchoice checkpoints on calls to Head (#10702) 2022-05-22 18:37:01 +00:00
service.go service.head race condition fix (#10741) 2022-05-27 14:24:43 +00:00
state_balance_cache_test.go Remove Eth2-Types Dependency in Prysm (#10578) 2022-04-29 10:32:11 -04:00
state_balance_cache.go Consolidate blockchain errors (#10736) 2022-05-22 17:48:54 +00:00
weak_subjectivity_checks_test.go Chain info: Return err if checkpoint is nil (#10729) 2022-05-20 18:41:33 +00:00
weak_subjectivity_checks.go Consolidate blockchain errors (#10736) 2022-05-22 17:48:54 +00:00