Substrate: Blockchain development framework
A modular framework for building custom blockchains with configurable consensus and runtime logic.
Learn more about Substrate
Substrate is a blockchain development framework that provides the foundational components for building custom blockchain networks. It implements a modular architecture where the runtime logic is separated from the client, allowing developers to customize consensus mechanisms, transaction processing, and governance systems. The framework uses WebAssembly for runtime execution and supports various consensus algorithms including proof-of-stake and proof-of-authority. Substrate serves as the foundation for Polkadot and other blockchain projects that require custom blockchain implementations.
Modular Architecture
Separates runtime logic from client implementation, allowing independent upgrades and customization of blockchain components without hard forks.
WebAssembly Runtime
Executes blockchain runtime in WebAssembly virtual machine, providing deterministic execution and enabling runtime upgrades through on-chain governance.
Configurable Consensus
Supports multiple consensus mechanisms including BABE, GRANDPA, and Aura, allowing developers to choose appropriate consensus for their use case.
use frame_support::{
construct_runtime, parameter_types,
traits::{KeyOwnerProofSystem, Randomness, StorageInfo},
weights::{constants::WEIGHT_REF_TIME_PER_SECOND, Weight},
};
use frame_system as system;
use pallet_balances as balances;
use sp_runtime::{
create_runtime_str, generic, impl_opaque_keys,
traits::{AccountIdLookup, BlakeTwo256, Block as BlockT, IdentifyAccount, Verify},
MultiSignature, Perbill,
};
construct_runtime!(
pub struct Runtime
where
Block = Block,
NodeBlock = opaque::Block,
UncheckedExtrinsic = UncheckedExtrinsic,
{
System: frame_system,
Timestamp: pallet_timestamp,
Balances: pallet_balances,
TransactionPayment: pallet_transaction_payment,
Sudo: pallet_sudo,
}
);
parameter_types! {
pub const BlockHashCount: BlockNumber = 2400;
pub const Version: RuntimeVersion = VERSION;
pub BlockWeights: frame_system::limits::BlockWeights =
frame_system::limits::BlockWeights::simple_max(
Weight::from_parts(2u64 * WEIGHT_REF_TIME_PER_SECOND, u64::MAX),
);
}monthly-2023-08: Automatic snapshot pre-release monthly-2023-08 Changes since last snapshot (monthly-2023-07)
- –Automatic snapshot pre-release monthly-2023-08 Changes since last snapshot (monthly-2023-07)
monthly-2023-07: Automatic snapshot pre-release monthly-2023-07 Changes since last snapshot (monthly-2023-06)
- –Automatic snapshot pre-release monthly-2023-07 Changes since last snapshot (monthly-2023-06)
monthly-2023-06: Automatic snapshot pre-release monthly-2023-06 Changes since last snapshot (monthly-2023-05)
- –Automatic snapshot pre-release monthly-2023-06 Changes since last snapshot (monthly-2023-05)
Related Repositories
Discover similar tools and frameworks used by developers
LND
Complete Lightning Network node implementation with channel management, payment routing, and BOLT specification compliance.
Hardhat
Development environment for compiling, deploying, testing, and debugging Ethereum smart contracts and dApps.
Bitcoin Core
Reference implementation of the Bitcoin protocol that connects to the peer-to-peer network for block validation.
MetaMask Extension
Browser extension that provides wallet functionality for interacting with Ethereum blockchain applications.
BitcoinJS
A TypeScript-based Bitcoin library providing cryptographic functions and transaction handling for Node.js and browsers.