Weights to u64 + Balances Weights (#5446)

Co-Authored-By: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
This commit is contained in:
Shawn Tabrizi
2020-04-16 10:43:18 +02:00
committed by GitHub
parent 1c7525fd4b
commit 980b635c8d
82 changed files with 636 additions and 428 deletions
+6 -1
View File
@@ -47,7 +47,7 @@ use sp_version::RuntimeVersion;
pub use sp_core::hash::H256;
#[cfg(any(feature = "std", test))]
use sp_version::NativeVersion;
use frame_support::{impl_outer_origin, parameter_types, weights::Weight};
use frame_support::{impl_outer_origin, parameter_types, weights::{Weight, RuntimeDbWeight}};
use sp_inherents::{CheckInherentsResult, InherentData};
use cfg_if::cfg_if;
use sp_core::storage::ChildType;
@@ -380,6 +380,10 @@ parameter_types! {
pub const BlockHashCount: BlockNumber = 250;
pub const MinimumPeriod: u64 = 5;
pub const MaximumBlockWeight: Weight = 4 * 1024 * 1024;
pub const DbWeight: RuntimeDbWeight = RuntimeDbWeight {
read: 100,
write: 1000,
};
pub const MaximumBlockLength: u32 = 4 * 1024 * 1024;
pub const AvailableBlockRatio: Perbill = Perbill::from_percent(75);
}
@@ -397,6 +401,7 @@ impl frame_system::Trait for Runtime {
type Event = Event;
type BlockHashCount = BlockHashCount;
type MaximumBlockWeight = MaximumBlockWeight;
type DbWeight = ();
type MaximumBlockLength = MaximumBlockLength;
type AvailableBlockRatio = AvailableBlockRatio;
type Version = ();