Allow Parity as ingest node (#36)

* Upgrade go-ethereum to v1.8

* Add Node Info for parity nodes

* Upgrade start_private_blockchain to use v1.8
This commit is contained in:
Matt K
2018-03-07 15:29:21 -06:00
committed by GitHub
parent 203f9b47d3
commit 5a652190d9
624 changed files with 77003 additions and 14158 deletions
+3 -3
View File
@@ -4,15 +4,15 @@ type Block struct {
Reward float64 `db:"reward"`
Difficulty int64 `db:"difficulty"`
ExtraData string `db:"extra_data"`
GasLimit int64 `db:"gaslimit"`
GasUsed int64 `db:"gasused"`
GasLimit uint64 `db:"gaslimit"`
GasUsed uint64 `db:"gasused"`
Hash string `db:"hash"`
IsFinal bool `db:"is_final"`
Miner string `db:"miner"`
Nonce string `db:"nonce"`
Number int64 `db:"number"`
ParentHash string `db:"parenthash"`
Size int64 `db:"size"`
Size string `db:"size"`
Time int64 `db:"time"`
Transactions []Transaction
UncleHash string `db:"uncle_hash"`
+28
View File
@@ -1,8 +1,36 @@
package core
import (
"fmt"
)
type NodeType int
const (
GETH NodeType = iota
PARITY
INFURA
)
type Node struct {
GenesisBlock string
NetworkID float64
ID string
ClientName string
}
type ParityNodeInfo struct {
Track string
ParityVersion `json:"version"`
Hash string
}
func (pn ParityNodeInfo) String() string {
return fmt.Sprintf("Parity/v%d.%d.%d/", pn.Major, pn.Minor, pn.Patch)
}
type ParityVersion struct {
Major int
Minor int
Patch int
}
+2 -2
View File
@@ -3,8 +3,8 @@ package core
type Receipt struct {
Bloom string
ContractAddress string
CumulativeGasUsed int64
GasUsed int64
CumulativeGasUsed uint64
GasUsed uint64
Logs []Log
StateRoot string
Status int
+1 -1
View File
@@ -6,7 +6,7 @@ type Transaction struct {
Nonce uint64 `db:"nonce"`
To string `db:"tx_to"`
From string `db:"tx_from"`
GasLimit int64 `db:"gaslimit"`
GasLimit uint64 `db:"gaslimit"`
GasPrice int64 `db:"gasprice"`
Receipt
Value string `db:"value"`