Skip to content

Genesis (Spec)

Yuanjun edited this page Nov 6, 2019 · 2 revisions

Spec

name

  type: String
  Name of a chain.
  It will be showed in log when you start aion kernal.

dataDir

  type: Option<String>
  Name of dir to distinguish data from different chains.
  For example: data_dir is mainnet which means db path of this chain is ~/.aion/chains/mainnet/db...

engine

  type:Engine
  Engine is an enum with two elements UnityEngine(UnityEngine) and Null(NullEngine).
  Set kind of engine and its parameters.

UnityEngine

params

rampupUpperBound

  type: Option<Uint>
  Upper bound of block number for block reward floating.

rampupLowerBound

  type: Option<Uint>
  Lower bound of block number for block reward floating.

rampupStartValue

  type: Option<Uint>
  Block reward minimum.

rampupEndValue

  type: Option<Uint>
  Block reward maximum.

lowerBlockReward

  type: Option<Uint>
  Block reward for block which number is less than rampupLowerBound.

upperBlockReward

  type: Option<Uint>
  Block reward for block which number is larger than rampupUpperBound.

difficultyBoundDivisor

  type: Option<Uint>
  Participate in the calculation of the difficulty unit of change before unity update.

difficultyBoundDivisorUnity

  type: Option<u64>
  Participate in the calculation of the difficulty unit of change after unity update.

blockTimeLowerBound

  type: Option<u64>
  Lower bound of blocks interval.

blockTimeUpperBound

  type: Option<u64>
  Upper bound of blocks interval.

blockTimeUnity

  type: Option<u64>
  Unity blocks interval.

minimumPoWDifficulty

  type: Option<Uint>

minimumPoSDifficulty

  type: Option<Uint>

NullEngine

  Temporarily reserved

params

blockReward

  type: Option<Uint>

params

maximumExtraDataSize

  type: Uint
  Maximum size of extra data.

minGasLimit

  type: Uint
  Minimum gas limit.

gasLimitBoundDivisor

  non_zero
  type: Uint
  Gas limit bound divisor (how much gas limit can change per block)

registrar

  type: Option<Address>
  Registrar contract address.

transactionPermissionContract

  type: Option<Address>
  Transaction permission contract address.

monetaryPolicyUpdate

  type: Option<Uint>
  Monetary policy update block number.

unityUpdate

  type: Option<Uint>
  Unity update block number.

genesis

seal

  type: Seal
  Seal is an enum with three elements POWEquihash(POWEquihash), Ethereum(Ethereum) and Generic(Bytes).

POWEquihash
nonce

  type: H256

solution

  type: Bytes

Ethereum
nonce

  type: H64

mixHash

  type: H256

Generic

difficulty

  type: Uint

author

  type: Option<Address>
  defaults to 0

timestamp

  type: Option<Uint>
  defaults to 0

parentHash

  type: Option<H256>
  defaults to 0

gasLimit

  type: Uint

transactionsRoot

  type: Option<H256>

receiptsRoot

  type: Option<H256>

stateRoot

  type: Option<H256>

gasUsed

  type: Option<Uint>

extraData

  type: Option<Bytes>

accounts

builtin

  type: Option<Builtin>
  Builtin contract

name

  type: String
  Builtin name.

activate_at

  type: Option<Uint>
  Activation block.

deactivate_at

  type: Option<Uint>
  Deactivation block.

owner_address

  type: Option<Address>
  Owner address.

address

  type: Option<Address>
  contract address. if not specified, it's the same with builtin's key.

balance

  type: Option<Uint>

nonce

  type: Option<Uint>

code

  type: Option<Bytes>

storage

  type: Option<BTreeMap<Uint, Uint>>

storage_dword

  type: Option<BTreeMap<Uint, Uint>>

constructor

  type: Option<Bytes>

Clone this wiki locally