Documentation ¶
Index ¶
- Constants
- func GenerateExecutionReceipt(signer module.Local, receiptHasher hash.Hasher, result *flow.ExecutionResult, ...) (*flow.ExecutionReceipt, error)
- func SPOCKProve(sk crypto.PrivateKey, data []byte, kmac hash.Hasher) (crypto.Signature, error)
- func SystemChunkContext(vmCtx fvm.Context) fvm.Context
- type BlockComputer
- type TransactionRequest
- type TransactionWriteBehindLogger
- type ViewCommitter
Constants ¶
View Source
const (
SystemChunkEventCollectionMaxSize = 256_000_000 // ~256MB
)
Variables ¶
This section is empty.
Functions ¶
func GenerateExecutionReceipt ¶ added in v0.30.0
func SPOCKProve ¶ added in v0.29.0
func SPOCKProve( sk crypto.PrivateKey, data []byte, kmac hash.Hasher, ) ( crypto.Signature, error, )
This is a temporary wrapper that simulates a call to SPoCK prove, required for the emulator build. The function is never called by the emulator although it is required for a successful build.
TODO(tarak): remove once the crypto module properly implements a non-relic version of SPOCKProve.
Types ¶
type BlockComputer ¶
type BlockComputer interface { ExecuteBlock( ctx context.Context, parentBlockExecutionResultID flow.Identifier, block *entity.ExecutableBlock, snapshot snapshot.StorageSnapshot, derivedBlockData *derived.DerivedBlockData, ) ( *execution.ComputationResult, error, ) }
A BlockComputer executes the transactions in a block.
func NewBlockComputer ¶
func NewBlockComputer( vm fvm.VM, vmCtx fvm.Context, metrics module.ExecutionMetrics, tracer module.Tracer, logger zerolog.Logger, committer ViewCommitter, signer module.Local, executionDataProvider provider.Provider, colResCons []result.ExecutedCollectionConsumer, state protocol.State, maxConcurrency int, ) (BlockComputer, error)
NewBlockComputer creates a new block executor.
type TransactionRequest ¶ added in v0.32.0
type TransactionRequest struct { *fvm.TransactionProcedure // contains filtered or unexported fields }
type TransactionWriteBehindLogger ¶ added in v0.32.0
type TransactionWriteBehindLogger interface { AddTransactionResult( txn TransactionRequest, snapshot *snapshot.ExecutionSnapshot, output fvm.ProcedureOutput, timeSpent time.Duration, numTxnConflictRetries int, ) }
type ViewCommitter ¶ added in v0.16.0
type ViewCommitter interface { // CommitView commits an execution snapshot and collects proofs CommitView( *snapshot.ExecutionSnapshot, flow.StateCommitment, ) ( flow.StateCommitment, []byte, *ledger.TrieUpdate, error, ) }
ViewCommitter commits execution snapshot to the ledger and collects the proofs
Source Files ¶
Click to show internal directories.
Click to hide internal directories.