diff options
author | Bojie Wu <bojie@dexon.org> | 2018-10-09 13:28:45 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-04-09 21:32:52 +0800 |
commit | 7c1386d928acd050684f435e49149696bcc0a637 (patch) | |
tree | db7141013bd1aa9e2349aa8b161d6529ff25cd40 /core/types/block.go | |
parent | d44a8b7003df87c7e7662a7ac86fb351872cd371 (diff) | |
download | dexon-7c1386d928acd050684f435e49149696bcc0a637.tar dexon-7c1386d928acd050684f435e49149696bcc0a637.tar.gz dexon-7c1386d928acd050684f435e49149696bcc0a637.tar.bz2 dexon-7c1386d928acd050684f435e49149696bcc0a637.tar.lz dexon-7c1386d928acd050684f435e49149696bcc0a637.tar.xz dexon-7c1386d928acd050684f435e49149696bcc0a637.tar.zst dexon-7c1386d928acd050684f435e49149696bcc0a637.zip |
app: add cache mechanism to increase performance
Diffstat (limited to 'core/types/block.go')
-rw-r--r-- | core/types/block.go | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/core/types/block.go b/core/types/block.go index 9e42a776a..07fc55358 100644 --- a/core/types/block.go +++ b/core/types/block.go @@ -75,25 +75,26 @@ type WitnessData struct { // Header represents a block header in the Ethereum blockchain. type Header struct { - ParentHash common.Hash `json:"parentHash" gencodec:"required"` - UncleHash common.Hash `json:"sha3Uncles" gencodec:"required"` - Coinbase common.Address `json:"miner" gencodec:"required"` - Root common.Hash `json:"stateRoot" gencodec:"required"` - TxHash common.Hash `json:"transactionsRoot" gencodec:"required"` - ReceiptHash common.Hash `json:"receiptsRoot" gencodec:"required"` - Bloom Bloom `json:"logsBloom" gencodec:"required"` - Difficulty *big.Int `json:"difficulty" gencodec:"required"` - Number *big.Int `json:"number" gencodec:"required"` - GasLimit uint64 `json:"gasLimit" gencodec:"required"` - GasUsed uint64 `json:"gasUsed" gencodec:"required"` - Time uint64 `json:"timestamp" gencodec:"required"` - Extra []byte `json:"extraData" gencodec:"required"` + ParentHash common.Hash `json:"parentHash" gencodec:"required"` + UncleHash common.Hash `json:"sha3Uncles" gencodec:"required"` + Coinbase common.Address `json:"miner" gencodec:"required"` + Root common.Hash `json:"stateRoot" gencodec:"required"` + TxHash common.Hash `json:"transactionsRoot" gencodec:"required"` + ReceiptHash common.Hash `json:"receiptsRoot" gencodec:"required"` + Bloom Bloom `json:"logsBloom" gencodec:"required"` + Difficulty *big.Int `json:"difficulty" gencodec:"required"` + Number *big.Int `json:"number" gencodec:"required"` + GasLimit uint64 `json:"gasLimit" gencodec:"required"` + GasUsed uint64 `json:"gasUsed" gencodec:"required"` + Time uint64 `json:"timestamp" gencodec:"required"` + Extra []byte `json:"extraData" gencodec:"required"` MixDigest common.Hash `json:"mixHash"` Nonce BlockNonce `json:"nonce"` - Randomness []byte `json:"randomness" gencodec:"required"` - Position coreTypes.Position `json:"position" gencodec:"required"` - Round uint64 `json:"round" gencodec:"required"` - DexconMeta []byte `json:"dexconMeta" gencodec:"required"` + Randomness []byte `json:"randomness" gencodec:"required"` + Position coreTypes.Position `json:"position" gencodec:"required"` + Round uint64 `json:"round" gencodec:"required"` + DexconMeta []byte `json:"dexconMeta" gencodec:"required"` + BlockReward *big.Int `json:"blockReward" gencodec:"required"` } // field type overrides for gencodec |