Documentation ¶
Index ¶
Constants ¶
const ( MilliCents = Cents / 1000 Cents = Dollar / 100 Dollar = Units Units uint64 = 10_000_000_000 )
const AuthoringVersion = 1
const BlockHashCount = sc.U32(2400)
const FiveMbPerBlockPerExtrinsic sc.U32 = 5 * 1024 * 1024
const ImplName = "node-template"
const ImplVersion = 1
const SpecName = "node-template"
const SpecVersion = 100
const StateVersion = 1
const StorageVersion = 0
const TransactionVersion = 1
const WeightRefTimePerNanos sc.U64 = 1_000
const WeightRefTimePerSecond sc.U64 = 1_000_000_000_000
Variables ¶
var ( KeySystem = []byte("System") KeyAccount = []byte("Account") KeyAllExtrinsicsLen = []byte("AllExtrinsicsLen") KeyAura = []byte("Aura") KeyAuthorities = []byte("Authorities") KeyBalances = []byte("Balances") KeyBlockHash = []byte("BlockHash") KeyBlockWeight = []byte("BlockWeight") KeyCurrentSlot = []byte("CurrentSlot") KeyDidUpdate = []byte("DidUpdate") KeyDigest = []byte("Digest") KeyEventCount = []byte("EventCount") KeyEvents = []byte("Events") KeyEventTopics = []byte("EventTopics") KeyExecutionPhase = []byte("ExecutionPhase") KeyExtrinsicCount = []byte("ExtrinsicCount") KeyExtrinsicData = []byte("ExtrinsicData") KeyExtrinsicIndex = []byte(":extrinsic_index") KeyGrandpaAuthorities = []byte(":grandpa_authorities") KeyLastRuntimeUpgrade = []byte("LastRuntimeUpgrade") KeyNextFeeMultiplier = []byte("NextFeeMultiplier") KeyNow = []byte("Now") KeyNumber = []byte("Number") KeyParentHash = []byte("ParentHash") KeyTimestamp = []byte("Timestamp") KeyTotalIssuance = []byte("TotalIssuance") KeyTransactionPayment = []byte("TransactionPayment") TransactionLevelKey = []byte(":transaction_level:") )
var AverageOnInitializeRatio types.Perbill = types.Perbill{Percentage: 10}
We assume that ~10% of the block weight is consumed by `on_initialize` handlers. This is used to limit the maximal weight of a single extrinsic.
var BlockExecutionWeight types.Weight = types.WeightFromParts(WeightRefTimePerNanos.SaturatingMul(412_772), 0)
Time to execute an empty block. Calculated by multiplying the *Average* with `1.0` and adding `0`.
Stats nanoseconds:
Min, Max: 402_748, 458_228 Average: 412_772 Median: 406_151 Std-Dev: 13480.33
Percentiles nanoseconds:
99th: 450_080 95th: 445_111 75th: 414_170
var DbWeight types.RuntimeDbWeight = types.RuntimeDbWeight{ Read: 25_000 * WeightRefTimePerNanos, Write: 100_000 * WeightRefTimePerNanos, }
DbWeight for RocksDB, used throughout the runtime.
var ExtrinsicBaseWeight types.Weight = types.WeightFromParts(WeightRefTimePerNanos.SaturatingMul(110_536), 0)
ExtrinsicBaseWeight is the time to execute a NO-OP extrinsic, for example `System::remark`. Calculated by multiplying the *Average* with `1.0` and adding `0`.
Stats nanoseconds:
Min, Max: 109_595, 114_170 Average: 110_536 Median: 110_233 Std-Dev: 933.39
Percentiles nanoseconds:
99th: 114_120 95th: 112_680 75th: 110_858
var FeeMultiplierUpdate types.WeightToFee = types.NewConstantMultiplier(sc.NewU128FromUint64(1))
var LengthToFee types.WeightToFee = types.IdentityFee{}
var MaximumBlockWeight types.Weight = types.WeightFromParts(WeightRefTimePerSecond.SaturatingMul(2), math.MaxUint64)
MaximumBlockWeight is the maximum weight 2 seconds of compute with a 6 second average block time, with maximum proof size.
var NormalDispatchRatio types.Perbill = types.Perbill{Percentage: 75}
We allow `Normal` extrinsics to fill up the block up to 75%, the rest can be used by Operational extrinsics.
var RuntimeVersion = types.RuntimeVersion{ SpecName: sc.Str(SpecName), ImplName: sc.Str(ImplName), AuthoringVersion: sc.U32(AuthoringVersion), SpecVersion: sc.U32(SpecVersion), ImplVersion: sc.U32(ImplVersion), Apis: sc.Sequence[types.ApiItem]{ { Name: sc.NewFixedSequence[sc.U8](8, 223, 106, 203, 104, 153, 7, 96, 155), Version: sc.U32(4), }, { Name: sc.NewFixedSequence[sc.U8](8, 55, 227, 151, 252, 124, 145, 245, 228), Version: sc.U32(1), }, { Name: sc.NewFixedSequence[sc.U8](8, 64, 254, 58, 212, 1, 248, 149, 154), Version: sc.U32(6), }, { Name: sc.NewFixedSequence[sc.U8](8, 210, 188, 152, 151, 238, 208, 143, 21), Version: sc.U32(3), }, { Name: sc.NewFixedSequence[sc.U8](8, 247, 139, 39, 139, 229, 63, 69, 76), Version: sc.U32(2), }, { Name: sc.NewFixedSequence[sc.U8](8, 221, 113, 141, 92, 197, 50, 98, 212), Version: sc.U32(1), }, { Name: sc.NewFixedSequence[sc.U8](8, 171, 60, 5, 114, 41, 31, 235, 139), Version: sc.U32(1), }, { Name: sc.NewFixedSequence[sc.U8](8, 237, 153, 197, 172, 178, 94, 237, 245), Version: sc.U32(3), }, { Name: sc.NewFixedSequence[sc.U8](8, 188, 157, 137, 144, 79, 91, 146, 63), Version: sc.U32(1), }, { Name: sc.NewFixedSequence[sc.U8](8, 55, 200, 187, 19, 80, 169, 162, 168), Version: sc.U32(3), }, { Name: sc.NewFixedSequence[sc.U8](8, 243, 255, 20, 213, 171, 82, 112, 89), Version: sc.U32(3), }, }, TransactionVersion: sc.U32(TransactionVersion), StateVersion: sc.U8(StateVersion), }
RuntimeVersion contains the version identifiers of the Runtime.
var WeightToFee types.WeightToFee = types.IdentityFee{}
var (
Zero = big.NewInt(0)
)
Functions ¶
This section is empty.
Types ¶
This section is empty.