Skip to main content

Crate linera_execution

Crate linera_execution 

Source
Expand description

This module manages the execution of the system application and the user applications in a Linera chain.

Re-exports§

pub use crate::committee::Committee;
pub use crate::committee::SharedCommittees;
pub use crate::execution_state_actor::ExecutionRequest;
pub use crate::execution_state_actor::ExecutionStateActor;
pub use crate::system::SystemExecutionStateView;
pub use crate::system::SystemMessage;
pub use crate::system::SystemOperation;
pub use crate::system::SystemQuery;
pub use crate::system::SystemResponse;

Modules§

committee
The committee of validators and their voting weights for an epoch.
execution_state_actor
Handle requests from the synchronous execution thread of user applications.
system
The system application implementing core chain functionality.

Structs§

BlobState
The state of a blob of binary data.
ExecutionRuntimeConfig
Configuration options for the execution runtime available to applications.
ExecutionStateView
A view accessing the execution state of a chain.
FinalizeContext
The context in which a transaction is finalized.
InvalidWasmRuntime
Attempts to create an invalid WasmRuntime instance from a string.
JsVec
A wrapper around a Vec that can be converted to and from a JavaScript array.
MessageContext
The context in which a message is executed.
OperationContext
The context in which an operation is executed.
OutgoingMessage
A posted message together with routing information.
ProcessStreamsContext
The context in which stream updates are processed.
QueryContext
The context in which a query is executed.
QueryOutcome
The outcome of the execution of a query.
ResourceControlPolicy
A collection of prices and limits associated with block execution.
ResourceController
Tracks and controls the resources used during execution, charging fees against an account.
ResourceTracker
The resources used so far by an execution process. Acts as an accumulator for all resources consumed during a specific execution flow. This could be the execution of a block, the processing of a single message, or a specific phase within these broader operations.
ServiceRuntimeEndpoint
How to interact with a long-lived service runtime.
ServiceSyncRuntime
The synchronous runtime used to execute service queries.
ThreadPool
A pool of shared resources, each of which can only be used once at a time.
TransactionOutcome
The TransactionTracker contents after a transaction has finished.
TransactionTracker
Tracks oracle responses and execution outcomes of an ongoing transaction execution, as well as replayed oracle responses.
UserContractCode
An implementation of UserContractModule.
UserServiceCode
An implementation of UserServiceModule.

Enums§

EvmRuntime
The runtime to use for running EVM smart contracts.
ExecutionError
A type for errors happening during execution.
Message
A message to be sent and possibly executed in the receiver’s block.
MessageKind
The kind of outgoing message being sent.
Operation
An operation to be executed in a block.
Query
An query to be sent and possibly executed in the receiver’s block.
QueryResponse
The response to a query.
ServiceRuntimeRequest
A request to the service runtime actor.
WasmRuntime
The runtime to use for running the application.

Constants§

FLAG_FREE_APPLICATION_ID_PREFIX
The prefix for flags that mark an application as free (message- and event-related fees waived). The full flag is FLAG_FREE_APPLICATION_ID_<APP_ID>.linera.network.
FLAG_FREE_APPLICATION_ID_SUFFIX
The suffix for free application ID flags.
FLAG_FREE_REJECT
The flag that deactivates charging for bouncing messages. If this is present, outgoing messages are free of charge if they are bouncing, and operation outcomes are counted only by payload size, so that rejecting messages is free.
FLAG_HISTORICAL_HASH
The flag that, if present in http_request_allow_list field of the content policy of the current committee, switches the execution-state hash to historical hashing: the first block after activation seeds the rolling hash from a full content hash (via HashableView), and every subsequent block extends it cheaply from the written batch. Takes effect only when FLAG_ZERO_HASH is absent. Enforced in consensus.
FLAG_HISTORICAL_HASH_SHADOW
Like FLAG_HISTORICAL_HASH, but in shadow mode: the rolling historical hash is computed, persisted and logged, yet the state hash reported to consensus stays all-zeros. This lets a network populate and cross-check historical hashes across validators (comparing the logged values) before enforcing them. Ignored if FLAG_ZERO_HASH or FLAG_HISTORICAL_HASH is present.
FLAG_MANDATORY_APPS_NEED_ACCEPTED_MESSAGE
The flag that makes mandatory application checks require accepted messages. If this is present, only accepted incoming messages (not rejected ones) satisfy the mandatory applications requirement for a block.
FLAG_ZERO_HASH
The flag that, if present in http_request_allow_list field of the content policy of current committee, causes the execution state not to be hashed, and instead the hash returned to be all zeros.
LINERA_SOL
The Linera.sol library code to be included in solidity smart contracts using Linera features.
LINERA_TYPES_SOL
The LineraTypes.sol library code defining the Solidity types used to interface with Linera features.

Traits§

BalanceHolder
How to access the balance of an account.
BaseRuntime
The runtime API shared by the contract and service parts of an application.
ContractRuntime
The runtime API available to the contract part of an application.
ExecutionRuntimeContext
Requirements for the extra field in our state views (and notably the ExecutionStateView).
ServiceRuntime
The runtime API available to the service part of an application.
UserContract
The public entry points provided by the contract part of an application.
UserContractModule
A factory trait to obtain a UserContract from a UserContractModule
UserService
The public entry points provided by the service part of an application.
UserServiceModule
A factory trait to obtain a UserService from a UserServiceModule
WithWasmDefault
Trait used to select a default WasmRuntime, if one is available.

Type Aliases§

ContractSyncRuntimeHandle
A handle to the synchronous runtime used when executing contracts.
ServiceSyncRuntimeHandle
A handle to the synchronous runtime used when executing services.
UserContractInstance
An implementation of UserContract.
UserServiceInstance
An implementation of UserService.