|
|
@ -141,11 +141,6 @@ var ( |
|
|
|
Usage: "Document Root for HTTPClient file scheme", |
|
|
|
Usage: "Document Root for HTTPClient file scheme", |
|
|
|
Value: DirectoryString{homeDir()}, |
|
|
|
Value: DirectoryString{homeDir()}, |
|
|
|
} |
|
|
|
} |
|
|
|
CacheFlag = cli.IntFlag{ |
|
|
|
|
|
|
|
Name: "cache", |
|
|
|
|
|
|
|
Usage: "Megabytes of memory allocated to internal caching (min 16MB / database forced)", |
|
|
|
|
|
|
|
Value: 128, |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
FastSyncFlag = cli.BoolFlag{ |
|
|
|
FastSyncFlag = cli.BoolFlag{ |
|
|
|
Name: "fast", |
|
|
|
Name: "fast", |
|
|
|
Usage: "Enable fast syncing through state downloads", |
|
|
|
Usage: "Enable fast syncing through state downloads", |
|
|
@ -154,6 +149,17 @@ var ( |
|
|
|
Name: "lightkdf", |
|
|
|
Name: "lightkdf", |
|
|
|
Usage: "Reduce key-derivation RAM & CPU usage at some expense of KDF strength", |
|
|
|
Usage: "Reduce key-derivation RAM & CPU usage at some expense of KDF strength", |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// Performance tuning settings
|
|
|
|
|
|
|
|
CacheFlag = cli.IntFlag{ |
|
|
|
|
|
|
|
Name: "cache", |
|
|
|
|
|
|
|
Usage: "Megabytes of memory allocated to internal caching (min 16MB / database forced)", |
|
|
|
|
|
|
|
Value: 128, |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
TrieCacheGenFlag = cli.IntFlag{ |
|
|
|
|
|
|
|
Name: "trie-cache-gens", |
|
|
|
|
|
|
|
Usage: "Number of trie node generations to keep in memory", |
|
|
|
|
|
|
|
Value: int(state.MaxTrieCacheGen), |
|
|
|
|
|
|
|
} |
|
|
|
// Fork settings
|
|
|
|
// Fork settings
|
|
|
|
SupportDAOFork = cli.BoolFlag{ |
|
|
|
SupportDAOFork = cli.BoolFlag{ |
|
|
|
Name: "support-dao-fork", |
|
|
|
Name: "support-dao-fork", |
|
|
@ -721,6 +727,10 @@ func RegisterEthService(ctx *cli.Context, stack *node.Node, extra []byte) { |
|
|
|
} |
|
|
|
} |
|
|
|
ethConf.PowTest = true |
|
|
|
ethConf.PowTest = true |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// Override any global options pertaining to the Ethereum protocol
|
|
|
|
|
|
|
|
if gen := ctx.GlobalInt(TrieCacheGenFlag.Name); gen > 0 { |
|
|
|
|
|
|
|
state.MaxTrieCacheGen = uint16(gen) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if err := stack.Register(func(ctx *node.ServiceContext) (node.Service, error) { |
|
|
|
if err := stack.Register(func(ctx *node.ServiceContext) (node.Service, error) { |
|
|
|
return eth.New(ctx, ethConf) |
|
|
|
return eth.New(ctx, ethConf) |
|
|
|