From adb04994560c2558fc93c85ea5976b3744ca6b6b Mon Sep 17 00:00:00 2001 From: Wei-Ning Huang Date: Thu, 15 Nov 2018 13:30:50 +0800 Subject: core: refactor validator and fix light node sync (#25) Remove custom Dexon validator by adding a new `ValidateWitnessData` method into the validator interface. This allow us to properly detect know blocks. This also allow other gdex "light" client to sync compaction chain. Also, setup a standalone RPC node for handling RPC reqeusts. --- cmd/utils/flags.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'cmd') diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go index 4ba319af0..b286c65c1 100644 --- a/cmd/utils/flags.go +++ b/cmd/utils/flags.go @@ -1171,6 +1171,10 @@ func SetDexConfig(ctx *cli.Context, stack *node.Node, cfg *dex.Config) { if ctx.GlobalIsSet(NetworkIdFlag.Name) { cfg.NetworkId = ctx.GlobalUint64(NetworkIdFlag.Name) } + if ctx.GlobalIsSet(BlockProposerEnabledFlag.Name) { + cfg.BlockProposerEnabled = ctx.GlobalBool(BlockProposerEnabledFlag.Name) + } + if ctx.GlobalIsSet(CacheFlag.Name) || ctx.GlobalIsSet(CacheDatabaseFlag.Name) { cfg.DatabaseCache = ctx.GlobalInt(CacheFlag.Name) * ctx.GlobalInt(CacheDatabaseFlag.Name) / 100 } -- cgit v1.2.3