From 7b804a5950981324e683085cbbcfee5fa9162f6f Mon Sep 17 00:00:00 2001 From: Jimmy Hu Date: Wed, 29 Aug 2018 10:55:23 +0800 Subject: core: Add agreement module (#77) --- simulation/config/config.go | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'simulation/config') diff --git a/simulation/config/config.go b/simulation/config/config.go index 0c6b5d3..6ead62e 100644 --- a/simulation/config/config.go +++ b/simulation/config/config.go @@ -33,10 +33,17 @@ const ( NetworkTypeTCPLocal NetworkType = "tcp-local" ) +// Agreement settings. +type Agreement struct { + CRS string + K int +} + // Consensus settings. type Consensus struct { - PhiRatio float32 - K int + Agreement Agreement + PhiRatio float32 + K int } // Validator config for the simulation. @@ -83,6 +90,10 @@ func GenerateDefault(path string) error { Title: "DEXON Consensus Simulation Config", Validator: Validator{ Consensus: Consensus{ + Agreement: Agreement{ + CRS: "In DEXON we trust.", + K: 50, + }, PhiRatio: float32(2) / 3, K: 1, }, -- cgit v1.2.3