|
|
@ -42,7 +42,7 @@ var ( |
|
|
|
commit string |
|
|
|
commit string |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
// InitLDBDatabase initializes a LDBDatabase. will return the beacon chain database for normal shard nodes
|
|
|
|
// InitLDBDatabase initializes a LDBDatabase. isGenesis=true will return the beacon chain database for normal shard nodes
|
|
|
|
func InitLDBDatabase(ip string, port string, freshDB bool, isBeacon bool) (*ethdb.LDBDatabase, error) { |
|
|
|
func InitLDBDatabase(ip string, port string, freshDB bool, isBeacon bool) (*ethdb.LDBDatabase, error) { |
|
|
|
var dbFileName string |
|
|
|
var dbFileName string |
|
|
|
if isBeacon { |
|
|
|
if isBeacon { |
|
|
@ -80,6 +80,8 @@ var ( |
|
|
|
minPeers = flag.Int("min_peers", 32, "Minimal number of Peers in shard") |
|
|
|
minPeers = flag.Int("min_peers", 32, "Minimal number of Peers in shard") |
|
|
|
// Key file to store the private key
|
|
|
|
// Key file to store the private key
|
|
|
|
keyFile = flag.String("key", "./.hmykey", "the p2p key file of the harmony node") |
|
|
|
keyFile = flag.String("key", "./.hmykey", "the p2p key file of the harmony node") |
|
|
|
|
|
|
|
// isGenesis indicates this node is a genesis node
|
|
|
|
|
|
|
|
isGenesis = flag.Bool("is_genesis", true, "true means this node is a genesis node") |
|
|
|
// isArchival indicates this node is an archival node that will save and archive current blockchain
|
|
|
|
// isArchival indicates this node is an archival node that will save and archive current blockchain
|
|
|
|
isArchival = flag.Bool("is_archival", true, "false makes node faster by turning caching off") |
|
|
|
isArchival = flag.Bool("is_archival", true, "false makes node faster by turning caching off") |
|
|
|
// delayCommit is the commit-delay timer, used by Harmony nodes
|
|
|
|
// delayCommit is the commit-delay timer, used by Harmony nodes
|
|
|
|