consensus/ethash: refactor remote sealer (#20335)
The original idea behind this change was to remove a use of the deprecated CancelRequest method. Simply removing it would've been an option, but I couldn't resist and did a bit of a refactoring instead. All remote sealing code was contained in a single giant function. Remote sealing is now extracted into its own object, remoteSealer.
Showing
- consensus/ethash/algorithm_test.go 1 addition, 1 deletionconsensus/ethash/algorithm_test.go
- consensus/ethash/api.go 10 additions, 16 deletionsconsensus/ethash/api.go
- consensus/ethash/ethash.go 34 additions, 78 deletionsconsensus/ethash/ethash.go
- consensus/ethash/sealer.go 210 additions, 141 deletionsconsensus/ethash/sealer.go
- consensus/ethash/sealer_test.go 39 additions, 68 deletionsconsensus/ethash/sealer_test.go
Loading
Please register or sign in to comment