Skip to content

Commit

Permalink
Merge branch 'master' into abi-encoding-decoding-function-call
Browse files Browse the repository at this point in the history
  • Loading branch information
franklywatson authored Jan 9, 2024
2 parents 5279398 + de63803 commit 777e121
Show file tree
Hide file tree
Showing 58 changed files with 5,056 additions and 2,195 deletions.
13 changes: 9 additions & 4 deletions cmd/execution_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -941,12 +941,19 @@ func (exeNode *ExecutionNode) LoadCheckerEngine(
module.ReadyDoneAware,
error,
) {
exeNode.checkerEng = checker.New(
if !exeNode.exeConf.enableChecker {
node.Logger.Warn().Msgf("checker engine is disabled")
return &module.NoopReadyDoneAware{}, nil
}

node.Logger.Info().Msgf("checker engine is enabled")

core := checker.NewCore(
node.Logger,
node.State,
exeNode.executionState,
node.Storage.Seals,
)
exeNode.checkerEng = checker.NewEngine(core)
return exeNode.checkerEng, nil
}

Expand Down Expand Up @@ -1056,8 +1063,6 @@ func (exeNode *ExecutionNode) LoadFollowerCore(
return nil, fmt.Errorf("could not find latest finalized block and pending blocks to recover consensus follower: %w", err)
}

exeNode.followerDistributor.AddFinalizationConsumer(exeNode.checkerEng)

// creates a consensus follower with ingestEngine as the notifier
// so that it gets notified upon each new finalized block
exeNode.followerCore, err = consensus.NewFollower(
Expand Down
2 changes: 2 additions & 0 deletions cmd/execution_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ type ExecutionConfig struct {
// file descriptors causing connection failures.
onflowOnlyLNs bool
enableStorehouse bool
enableChecker bool
}

func (exeConf *ExecutionConfig) SetupFlags(flags *pflag.FlagSet) {
Expand Down Expand Up @@ -118,6 +119,7 @@ func (exeConf *ExecutionConfig) SetupFlags(flags *pflag.FlagSet) {

flags.BoolVar(&exeConf.onflowOnlyLNs, "temp-onflow-only-lns", false, "do not use unless required. forces node to only request collections from onflow collection nodes")
flags.BoolVar(&exeConf.enableStorehouse, "enable-storehouse", false, "enable storehouse to store registers on disk, default is false")
flags.BoolVar(&exeConf.enableChecker, "enable-checker", true, "enable checker to check the correctness of the execution result, default is true")

}

Expand Down
Loading

0 comments on commit 777e121

Please sign in to comment.