Trait timestamp::TimestampConfig 
source · pub trait TimestampConfig {
    const MINIMUM_TIME_INTERVAL: u64 = 2_000u64;
    const MAX_DRIFT: u64 = 60_000u64;
    const MIN_TIME_BEFORE_CLEANUP: u64 = 86_400_000u64;
    const MIN_BLOCKS_BEFORE_CLEANUP: u32 = 15_000u32;
    // Required method
    fn block_height() -> u32;
}Expand description
Options to configure the timestamp piece in your runtime. Currently we only need access to a block number.
Provided Associated Constants§
sourceconst MINIMUM_TIME_INTERVAL: u64 = 2_000u64
 
const MINIMUM_TIME_INTERVAL: u64 = 2_000u64
The minimum amount of time by which the timestamp may be updated.
The default is 2 seconds which should be slightly lower than most chains’ block times.
sourceconst MAX_DRIFT: u64 = 60_000u64
 
const MAX_DRIFT: u64 = 60_000u64
The maximum amount by which a valid block’s timestamp may be ahead of an importing node’s current local time.
Default is 1 minute.
sourceconst MIN_TIME_BEFORE_CLEANUP: u64 = 86_400_000u64
 
const MIN_TIME_BEFORE_CLEANUP: u64 = 86_400_000u64
The minimum amount of time that must have passed before an old timestamp may be cleaned up.
Default is 1 day.
sourceconst MIN_BLOCKS_BEFORE_CLEANUP: u32 = 15_000u32
 
const MIN_BLOCKS_BEFORE_CLEANUP: u32 = 15_000u32
The minimum number of blocks that must have passed before an old timestamp may be cleaned up.
Default is 15 thousand which is roughly equivalent to 1 day with 6 second block times which is a common default in Substrate chains because of Polkadot.
Required Methods§
sourcefn block_height() -> u32
 
fn block_height() -> u32
A means of getting the current block height. Probably this will be the Tuxedo Executive