aboutsummaryrefslogtreecommitdiffstats
path: root/cmd
diff options
context:
space:
mode:
authorWei-Ning Huang <w@dexon.org>2018-11-15 13:30:50 +0800
committerWei-Ning Huang <w@dexon.org>2018-12-19 20:54:27 +0800
commitadb04994560c2558fc93c85ea5976b3744ca6b6b (patch)
tree6fb38620a06572fc5d51eefbee2e2646b807449f /cmd
parent61c27beb30c6b8919e3f83bee490bc75426dfa48 (diff)
downloaddexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar.gz
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar.bz2
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar.lz
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar.xz
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.tar.zst
dexon-adb04994560c2558fc93c85ea5976b3744ca6b6b.zip
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.
Diffstat (limited to 'cmd')
-rw-r--r--cmd/utils/flags.go4
1 files changed, 4 insertions, 0 deletions
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
}